Image Button Click Fired Edit Event.

Jayakumars
Posted by Jayakumars under ASP.NET AJAX category on | Points: 40 | Views : 640
I have Post the Code
Image Button Click Fired Edit Event.
==========================================
Client Side
================
<asp:ImageButton ID="ImgbtnEdit" runat="server" OnClick="ImgbtnEdit_Click" ToolTip="Edit"
Width="20px" Style="float: left" Height="20px" ImageUrl="~/images/edit.png" />

Server Side.
================
protected void ImgbtnEdit_Click(object sender, ImageClickEventArgs e)
{
try
{
ImageButton btnEditDetails = sender as ImageButton;
GridViewRow gvRow = (GridViewRow)btnEditDetails.NamingContainer;
Label EditId = (Label)gvRow.FindControl("LblId");
ViewState["EditId"] = EditId.Text;
}
catch (Exception Ex)
{

}
}

Comments or Responses

Login to post response