The reason is because CssClass is a property of the WebControl class whereas
<td runat=server...> makes an instance of the HtmlTableCell class which is a
descendant of the HtmlControl as opposed to WebControl.
--
Eliyahu Goldin,
Software Developer & Consultant
Microsoft MVP [ASP.NET]
http://msmvps.com/blogs/egoldin
http://usableasp.net
"Larry Bud" <> wrote in message
news: oups.com...
>
> Eliyahu Goldin wrote:
>> There is mycell.Attributes["class"]. Is it what you are after?
>>
>> --
>> Eliyahu Goldin,
>> Software Developer & Consultant
>> Microsoft MVP [ASP.NET]
>> http://msmvps.com/blogs/egoldin
>> http://usableasp.net
>>
>>
>> "Larry Bud" <> wrote in message
>> news: ups.com...
>> > Can it be done?
>> >
>> > I have a table, and in the <TD> I have <Td runat="server" id="mycell"
>> > class="myclass"></td>
>> >
>> > In the code behind, I can access mycell.style, but there is no
>> > mycell.CssClass...
>
> That's it. Seems odd that I can't refer to CssClass like with other
> elements.
>
>> >
>