asp:DataGrid ... how do I set a class for the first TR tag?

  • Thread starter Thread starter John
  • Start date Start date
J

John

Hi,

First off .. I am very new to ASP.NET (.NET in general), so this may be a
very basic question.

I have traditionally used a set of style classes for html tables and the
first row in those tables. However, I am trying to use a data bound
DataGrid and can't seem to figure out how to set the class for the first
row. Any insight would be appreiciated.

Thanks in advance,
John
 
The first row in a datagrid would be your header, so in <HeaderStyle>, you
can use your class.

Jeffrey Palermo
 
Thanks Jeffery.

Just for the record & precision. It's the CssClass attribute.

<HeaderStyle CssClass="myclass">
</HeaderStyle>

or

<asp:DataGrid
HeaderStyle-CssClass="myclass"
runat="server"/>

Thanks again.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top