J
Jimmy
Hi
In my headertemplate I do not get the column like in the itemtemplate ( I am
using the northwind db):
<asp:datagrid id="DataGrid1" style="Z-INDEX: 101; LEFT: 24px; POSITION:
absolute; TOP: 24px" runat="server"
BorderColor="#999999" BorderStyle="Solid" BorderWidth="1px"
BackColor="White" CellPadding="3"
GridLines="Vertical" ForeColor="Black" Height="224px"
AutoGenerateColumns="False" Width="536px">
<FooterStyle BackColor="#CCCCCC"></FooterStyle>
<SelectedItemStyle Font-Bold="True" ForeColor="White"
BackColor="#000099"></SelectedItemStyle>
<AlternatingItemStyle BackColor="#CCCCCC"></AlternatingItemStyle>
<HeaderStyle Font-Bold="True" ForeColor="White" BackColor="Black"
Height="200"></HeaderStyle>
<PagerStyle HorizontalAlign="Center" ForeColor="Black"
BackColor="#999999"></PagerStyle>
<Columns>
<asp:TemplateColumn>
<HeaderTemplate>
Customerid:
<asp:Label ID=test Runat=server text='<%#
DataBinder.Eval(Container.DataItem, "customerid") %>'>
</asp:Label>
</HeaderTemplate>
</asp:TemplateColumn>
</Columns>
<Columns>
<asp:TemplateColumn>
<ItemTemplate>
<%# DataBinder.Eval(Container.DataItem, "customerid") %>
</ItemTemplate>
</asp:TemplateColumn>
</Columns>
</asp:datagrid>
what could be wrong?
ch Jim
In my headertemplate I do not get the column like in the itemtemplate ( I am
using the northwind db):
<asp:datagrid id="DataGrid1" style="Z-INDEX: 101; LEFT: 24px; POSITION:
absolute; TOP: 24px" runat="server"
BorderColor="#999999" BorderStyle="Solid" BorderWidth="1px"
BackColor="White" CellPadding="3"
GridLines="Vertical" ForeColor="Black" Height="224px"
AutoGenerateColumns="False" Width="536px">
<FooterStyle BackColor="#CCCCCC"></FooterStyle>
<SelectedItemStyle Font-Bold="True" ForeColor="White"
BackColor="#000099"></SelectedItemStyle>
<AlternatingItemStyle BackColor="#CCCCCC"></AlternatingItemStyle>
<HeaderStyle Font-Bold="True" ForeColor="White" BackColor="Black"
Height="200"></HeaderStyle>
<PagerStyle HorizontalAlign="Center" ForeColor="Black"
BackColor="#999999"></PagerStyle>
<Columns>
<asp:TemplateColumn>
<HeaderTemplate>
Customerid:
<asp:Label ID=test Runat=server text='<%#
DataBinder.Eval(Container.DataItem, "customerid") %>'>
</asp:Label>
</HeaderTemplate>
</asp:TemplateColumn>
</Columns>
<Columns>
<asp:TemplateColumn>
<ItemTemplate>
<%# DataBinder.Eval(Container.DataItem, "customerid") %>
</ItemTemplate>
</asp:TemplateColumn>
</Columns>
</asp:datagrid>
what could be wrong?
ch Jim