You need to add a .ToString() to the Font.Size statement. Example:
& (Font.Size.ToString() & (";FONT-FAMILY: " _
Also, based on what you're doing, you probably want to use the
Font.SizeInPoints property.
HTH,
Matt Dinovo
"Jon Paal" <Jon nospam Paal @ everywhere dot com> wrote in message
news:%23VYR6$...
> why the error ?
>
> Compiler Error Message: BC30452: Operator '&' is not defined for types
> 'System.Web.UI.WebControls.FontUnit' and 'String'.
>
> Source Error:
>
>
> Line 203: writer.AddAttribute("border", "1")
> Line 204: writer.AddAttribute("style", ("FONT-SIZE: " _
> Line 205: & (Font.Size & (";FONT-FAMILY: " _
> Line 206: & (Font.Name & ";BORDER-COLLAPSE:
> collapse")))))
> Line 207: writer.AddAttribute("borderColor", "#000000")
>
> Source File: C:\..\test.vb Line: 205
>
>
>
|