We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

how to highlight selection for nested table ? for GGC


hi,

i can easily do the selection of the first level table (say, the datasource is nested datatable) of GGC. Then do right click menu pop up.

how to highlight selection for nested table ? for GGC.

David


3 Replies

RC Rajadurai C Syncfusion Team April 7, 2009 03:13 PM UTC

Hi David,

Thanks for your interest in Syncfusion products.

The style information of the nested table records can be accessed thorough the Table and TableControl properties in gridgroupingcontrol.

Please refer to the following KB link that deals with this.
http://www.syncfusion.com/support/kb/grid/Default.aspx?ToDo=view&questId=295

Please let me know if you have any further concerns.

Regards,
Rajadurai



DC David Cui April 7, 2009 07:00 PM UTC

Rajadurai,

Thanks a lot! Maybe I didn't make myself clear. Let me say this: 1. i put the selection mode as following


this.gridGroupingControl1.TableModel.Options.SelectCellsMouseButtonsMask = MouseButtons.Left;

this.gridGroupingControl1.TableOptions.AllowSelection = Syncfusion.Windows.Forms.Grid.GridSelectionFlags.Any;
this.gridGroupingControl1.TableOptions.ListBoxSelectionMode = System.Windows.Forms.SelectionMode.None;


2. i can highlight range of cells, it triggers tableModel.selectionChanged event. so i do some cell summation within the selection changed event. it works fine .

3. i expand one record, try to highlight range of cells at child (nested) table. somehow it doesn't trigger selectionChanged event. That is my question. Am I clear ?
does the nested table selectionChanged event need to be explicitly hooked up by other way ?

4. if you need example, just replace step one steps into your provided example above. you can mimic what i am talking about.


thx.

David




>Hi David,

Thanks for your interest in Syncfusion products.

The style information of the nested table records can be accessed thorough the Table and TableControl properties in gridgroupingcontrol.

Please refer to the following KB link that deals with this.
http://www.syncfusion.com/support/kb/grid/Default.aspx?ToDo=view&questId=295

Please let me know if you have any further concerns.

Regards,
Rajadurai





RC Rajadurai C Syncfusion Team April 9, 2009 11:31 AM UTC

Hi David,

Thanks for your details.

By default, the table model points to the parent grid model. To get with the events of tablemodel, you can access the tablemodel of the specific table and hook events there. Please refer to the following code.

GridTableModel model = this.gridGroupingControl1.GetTableModel("ChildTable");
model.SelectionChanged += new GridSelectionChangedEventHandler(model_SelectionChanged);

//Event
void model_SelectionChanged(object sender, GridSelectionChangedEventArgs e)
{
//code
}


Please let me know if you have any further concerns.

Regards,
Rajadurai


Loader.
Live Chat Icon For mobile
Up arrow icon