I have my own method and I am trying to findcontrol on a control inside the GridTemplateColumn, so I am doing it outside of the events for the radGrid. Is this possible and if so, how?
Thanks!
Try with below code.
<telerik:GridTemplateColumn>
<ItemTemplate>
<asp:Label ID="Label1"></asp:Label>
</ItemTemplate>
<EditItemTemplate>
<asp:TextBox ID="TextBox1"></asp:TextBox>
</EditItemTemplate>
</telerik:GridTemplateColumn>
...................
button1_click()
{
// for Normal mode
foreach (GridDataItem item in RadGrid1.MasterTableView.Items)
{
Label Label1 = item.FindControl("Label1") as Label;
}
// for edit mode
foreach (GridDataItem item in RadGrid1.EditItems)
{
TextBox TextBox1 = item.FindControl("TextBox") as TextBox;
}
}
Thanks, Jayesh Goyani