I would like to find a user control that I am using in my RadGrid Edittemplate, but I cannot.
I am able to find it in the ItemDataBound event, but I cannot find it at ItemCommand where I need to access a control within it.
This is how I access the usercontrol in ItemDataBound event:
I am able to find it in the ItemDataBound event, but I cannot find it at ItemCommand where I need to access a control within it.
This is how I access the usercontrol in ItemDataBound event:
Protected Sub rg_ItemDataBound(sender As Object, e As Telerik.Web.UI.GridItemEventArgs)
If TypeOf (e.Item) Is GridEditFormItem And Not rg.MasterTableView.IsItemInserted Then
Dim e_item As GridEditFormItem = CType(e.Item, GridEditFormItem)
Dim uc As UserControl = CType(CType(e.Item, GridEditFormItem).FindControl("EditFormControl"), UserControl)
End If
End Sub
This works but does not in ItemCommand.