Hi all,
I have installed for Insert Command with code in ItemCommand event:
if (e.CommandName == RadGrid.InitInsertCommandName)
{
e.Canceled = true;
e.Item.OwnerTableView.InsertItem();
e.Item.OwnerTableView.IsItemInserted = true;
GridEditableItem insertedItem = e.Item.OwnerTableView.GetInsertItem();
String MyUserControlId = GridEditFormItem.EditFormUserControlID;
UserControl userControl = insertedItem.FindControl(MyUserControlId) as UserControl;
}
this run well.
However, I don't know how to find my usercontrol when click Edit command. Please help me!
Thanks!
I have installed for Insert Command with code in ItemCommand event:
if (e.CommandName == RadGrid.InitInsertCommandName)
{
e.Canceled = true;
e.Item.OwnerTableView.InsertItem();
e.Item.OwnerTableView.IsItemInserted = true;
GridEditableItem insertedItem = e.Item.OwnerTableView.GetInsertItem();
String MyUserControlId = GridEditFormItem.EditFormUserControlID;
UserControl userControl = insertedItem.FindControl(MyUserControlId) as UserControl;
}
this run well.
However, I don't know how to find my usercontrol when click Edit command. Please help me!
Thanks!