jkw119
Aug 19th, 2002, 07:57 AM
Does anyone know how to change the color of a datagrid column.
Thanks
Jeff
FatDaz
Aug 19th, 2002, 08:57 AM
The simplest way is using the property builder. In DESIGN view, right click the datagrid, and choose, PROPERTY BUILDER.
Choose Format ->
Columns ->
Pick the column you're interested ->
Pick Items ->
Then you can change the specific properties for items displayed in that column.
Or in HTML code you can use for example...
<asp:DataGrid id="DataGrid1" runat="server">
<Columns>
<asp:ButtonColumn>
<ItemStyle BackColor="LightCoral"></ItemStyle>
</asp:ButtonColumn>
<asp:ButtonColumn>
<ItemStyle BackColor="Bisque"></ItemStyle>
</asp:ButtonColumn>
</Columns>
</asp:DataGrid>