I've never encountered any problems with including
th
{
background-color: #900;
}
as a CSS style in a file and having it affect the header row of an ASP datagrid. However, today I'm facing an issue where everything in my grid is being output within TBODY tags, even the headers are in TD tags. Any thoughts on this?
One thing to note is that this grid is bound to a List instead of a DataTable. Is this standard behavior? Is there a simple solution?
UPDATE
<asp:DataGrid ID="dgEmployees" runat="server">
</asp:DataGrid>
THE VALUE OF AN IDE It turns out that my DataGrid should have been a GridView. Lesson learned not to manually type in HTML tags again. I couldn't figure out what I had done wrong until I compared it with another project of mine.