Anonymous
public text v1 · immutableif (e.Row.RowType == DataControlRowType.DataRow)
{
if (e.Row.DataItemIndex == -1) return;
e.Row.Attributes.Add("onMouseOver", "this.style.cursor='hand';");
e.Row.Attributes.Add("onclick", ClientScript.GetPostBackEventReference(gvTools, "Edit$" + e.Row.RowIndex.ToString() ) );
// The above code simply writes a postback client event's JavaScript on the "OnClick" event of that control.
// When we click on the control, it calls the Edit functionality of the DataGrid.
}