error setting headerimageurl in asp:TemplateColumn

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi guys,
i have the following code in Datagrid:
<asp:TemplateColumn HeaderText="Delete"
headerImageUrl=../../Images/i.p.delete.gif">
<ItemTemplate>
<asp:CheckBox ID=Chk1 Enabled="True" runat="server" />
</ItemTemplate>
</asp:TemplateColumn>

when i run the page, i get the following error:

System.Web.UI.WebControls.DataGridColumnCollection must have items of type
'System.Web.UI.WebControls.DataGridColumn'. 'ItemTemplate' is of type
'System.Web.UI.HtmlControls.HtmlGenericControl'.

Can someone tell me whats wrong and how to fix it?

Thanks
Manny
 
Your missing the opening double quote on headerImageUrl attribute.

<asp:TemplateColumn HeaderText="Delete"
headerImageUrl="../../Images/i.p.delete.gif">

-Chris
 

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