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

Update problem - self referencing hierarchical grid with multiple parents

2 Answers 77 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Clinton Smyth
Top achievements
Rank 1
Clinton Smyth asked on 10 Oct 2012, 11:49 PM
Hi

We have a self referencing hierarchical grid that contains rows with multiple parents.  For example, if I denote '->' as 'is a parent of', then we have:
A -> B -> C
A -> D -> C

Note that C is a repeated row in the GridData.

Now C also has child rows, ie.:
C -> D
C -> E

The RadGrid correctly displays the children of C under each occurrence of C (even though nodes D & E are not repeated in the GridData).  The grid (correctly again), treats each occurrence of D and E as the same (i.e. references to 1 object and not copies of it).

The problem appears when I set D or E to IsCurrent (i.e. dataCell.RowInfo.IsCurrent = true; where D or E is contained in the dataCell).  Both rows get highlighted which is great, however, when the user double-clicks on the cell to edit it, the edit box appears on the first occurrence, even if they double-click on the 2nd or other occurrences.  Additionally, once edited only the first occurrence (where the edit box appears) changes it's value on the screen.

So how do I:
1. Make the edit box appear on the row that the user double-clicked on?
2. Update all occurrences of the same record on the screen?

Thanks

2 Answers, 1 is accepted

Sort by
0
Accepted
Julian Benkov
Telerik team
answered on 11 Oct 2012, 02:28 PM
Hello Clinton,

Thank you for writing.

RadGridView does not support multiple parents by design. The rendered view or data manipulation in this scenario can produce unexpected results during the usage of the grid control in run-time.

I hope this information is useful. Feel free to ask if you have additional questions or issues.

Greetings,
Julian Benkov
the Telerik team
You’ve been asking for it and now it’s time for us to deliver. RadControls for WinForms Q3 2012 release is just around the corner. Sign up for a free webinar to see first all the latest enhancements.
0
Clinton Smyth
Top achievements
Rank 1
answered on 11 Oct 2012, 04:21 PM
Thanks for your quick response.  I'm sorry to hear that you don't support multiple inheritance.  We'll look into alternative solutions.
Tags
GridView
Asked by
Clinton Smyth
Top achievements
Rank 1
Answers by
Julian Benkov
Telerik team
Clinton Smyth
Top achievements
Rank 1
Share this question
or