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

[Solved] Put all items in edit mode - DetailTable

5 Answers 104 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Mladen
Top achievements
Rank 1
Mladen asked on 23 Sep 2009, 03:49 PM
Hi,

is there example or demo on this site,  similar to the existing one - "Put All items in edit mode ...", but with hierarchical grid.
After expanding some of the DetalTable child grids, all child items should be putted in edit mode automattically.

Thanks in advance. 

5 Answers, 1 is accepted

Sort by
0
Mr. Plinko
Top achievements
Rank 1
answered on 23 Sep 2009, 03:59 PM
This link on Default edit mode for grid items on initial load describes how to do it in the code behind using the following:

foreach(GridItem item in RadGrid1.MasterTableView.Items) 
 { 
  if (item is GridEditableItem) 
  { 
   GridEditableItem editableItem= item as GridDataItem; 
   editableItem.Edit = true
  } 
 } 

You could try RadGrid1.MasterTableView.DetailTable.Items instead.
0
Mr. Plinko
Top achievements
Rank 1
answered on 23 Sep 2009, 03:59 PM
duplicate post
0
Mladen
Top achievements
Rank 1
answered on 23 Sep 2009, 04:37 PM
Ok, I have considered this, but I don't know where to put this code, which event is best for OnDemand expanding detailTables.
I have already tried events like: OnDataBound, OnItemDataBount, OnItemCreated ..., in all of this I get some error.

Thanks again.
0
Mladen
Top achievements
Rank 1
answered on 23 Sep 2009, 04:51 PM
I think PreRender event could be good option for this problem, but I still have no working version.


0
Mr. Plinko
Top achievements
Rank 1
answered on 23 Sep 2009, 04:54 PM
What error are you getting?

Also, are you setting AllowMultiRowEdit to true?
Tags
Grid
Asked by
Mladen
Top achievements
Rank 1
Answers by
Mr. Plinko
Top achievements
Rank 1
Mladen
Top achievements
Rank 1
Share this question
or