I have a WebDataGrid where EnableAjax="false." One of the columns contains an ImageButton, as follows:
<Columns> <ig:BoundDataField DataFieldName="FileName" Key="FileName"> <Header CssClass="WebDataGrid_Header" Text="File Name" /> </ig:BoundDataField> <ig:TemplateDataField Key="Delete"> <ItemTemplate> <asp:ImageButton ID="imgDelete" OnClick="DeleteClick" CausesValidation="false" CommandName="D" ImageUrl="~/images/icon_delete.gif" runat="server" /> </ItemTemplate> </ig:TemplateDataField> </Columns>
The Click Event for the image button is as follows:
protected void DeleteClick(object sender, EventArgs e) {
}
But, when I click the button, the event never fires. Can anyone explain why, and possibly provide a solution?
hi RadoSlav,
The Image button onCommand event is not firing in the Infragistics webdatagrid 14.2 but it working when we are using the Infragistics 12.1
Hello guys,
Please have a look at the attached sample.
Hope it helps.
How would I databind the commandArgument to include the PKey of the row?
Assuming it is in a column called RowPKey
Thanks
jack
Can you re-post the sample? I'm having the same problem.
Jeff
Hello,
Attached is working sample showing how to use ItemCommand along with asp ImageButton control. ig_res folder was removed from the website due to upload size limitation.
Hope this helps.