I am currently working my way through a tutorial from my asp.net book and am slowly getting an understanding how this type of coding works. However, I have come to a standstill with the code below.
The line of code thats causing problems is:Code:<asp:dataGrid ID="myWinningBids" AutoGenerateColumns="False" Width="50%" HeaderStyle-BackColor="#ff0000" HeaderStyle-Font-Bold="True" HeaderStyle-Font-Name="Verdana" HeaderStyle-Font-Size="13px" HeaderStyle-ForeColor="#ffffff" ItemStyle-BackColor="Beige" ItemStyle-Font-Name="verdana" ItemStyle-Font-Size="13px" BorderColor="#000000" OnItemCreated="myWinningBids_ItemCreated" Runat="server"> <Columns> <asp:TemplateColumn HeaderText="Item Name - Click to Complete purchase."> <ItemTemplate> <asp:hyperlink ID="hypItemName" NavigateUrl='<%# FormatURL(DataBinder.Eval(Container.DataItem, "ItemID"), DataBinder.Eval(Container.DataItem, "Highestbid")) %>' Text='<%# DataBinder.Eval(Container.DataItem, "ItemName") %>' Runat=server /> </ItemTemplate> </asp:TemplateColumn> <asp:BoundColumn DataField="HighestBid" HeaderText="Winning Bid" runat="server" ID="Boundcolumn1" NAME="Boundcolumn1" /> </Columns> </asp:dataGrid>
The attributes ID and NAME are underline in red (In VS.net) and thier tooltip text says 'Counld not find any attribute 'ID' of element 'BoundColumn'Code:<asp:BoundColumn DataField="HighestBid" HeaderText="Winning Bid" runat="server" ID="Boundcolumn1" NAME="Boundcolumn1" />
Has anyone had this problem before? Or have I coded it wrongly?
Thanks




Reply With Quote