This is a migrated thread and some comments may be shown as answers.

Hierarchical Radgrid Expand collapse

1 Answer 125 Views
Grid
This is a migrated thread and some comments may be shown as answers.
VIJAY
Top achievements
Rank 1
VIJAY asked on 01 Jun 2012, 05:36 AM
I ma using 2 level hierarchical radgrid. In that i want at a time only one data can be inserted or updated. Like if we click on add link and then on edit link then add link should be closed . In the same way no two edit rows can be opened at a time.


Below is the demo which i am referring:
http://demos.telerik.com/aspnet-ajax/grid/examples/dataediting/threelevel/defaultcs.aspx

1 Answer, 1 is accepted

Sort by
0
Eyup
Telerik team
answered on 05 Jun 2012, 03:10 PM
Hello Vijay,

Thank you for contacting us.

Please try the following code:
protected void RadGrid1_ItemCommand(object source, GridCommandEventArgs e)
   {
       if (e.CommandName == RadGrid.EditCommandName)
       {
           RadGrid1.MasterTableView.IsItemInserted = false;
       }
       if (e.CommandName == RadGrid.InitInsertCommandName)
       {
           RadGrid1.MasterTableView.ClearEditItems();
       }
   }

That should do the trick. Please give it a try and let me know about the result.

Greetings,
Eyup
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Tags
Grid
Asked by
VIJAY
Top achievements
Rank 1
Answers by
Eyup
Telerik team
Share this question
or