I am binding the data to GridView control. One of the last column has the Image URL link.
<asp:GridView ID="gvSearchResults" runat="server" AutoGenerateColumns="False" Width="100%" OnRowCommand="gvccase_RowCommand" RowStyle-CssClass="rowHover">……..
<asp:TemplateField>
<ItemTemplate>
<asp:ImageButton ID="lnbEdit" AlternateText="edit" ImageUrl="~/images/edit_icon.gif"
runat="server" CommandName="cmdEdit" />
</ItemTemplate>
<HeaderTemplate>
Edit
</HeaderTemplate>
</asp:TemplateField>
When the user clicks on the last column the OnRowCommnd event(protected void gvccase_RowCommand(object sender, System.Web.UI.WebControls.CommandEventArgs e)) is called.
How to read which row the user clicked? Column one has Case#. I would like to read the Case # in the “OnRowCommand”. How to do it?
OR All I want to accomplish is.... when the user clicks on a particular row I want to take them to the details page.
Thank you, Smith