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.
Unfortunately, activation email could not send to your email. Please try again.

Complete Iteration of GridGroupingControl

Thread ID:

Created:

Updated:

Platform:

Replies:

28183 Apr 26,2005 07:53 AM Apr 26,2005 04:32 PM Windows Forms 1
loading
Tags: GridControl
Prithvi
Asked On April 26, 2005 07:53 AM

Hi, I am using version 3.0.1.0 of GridGroupingControl and with hierarchicial display of data and with groupby, I am trying to loop through all the cells in a GridGroupingControl, I have tried to use the GGC.Table.TableModel[rowIndex,colIndex].FormattedText method but I only get the top level table cells. I am looking to get the data in the cells exactly as visible in the grid layout(including the caption rows'' text). Is there any way this can be done? I have also tried using GGC.Engine.GetEnumarator to obtain the different tables, but I miss out the caption rows, if I use the GGC.Table.DisplayElements then I am not able to reach the nested tables to get the data. Can you please suggest suitable techiniques for complete "what you see is what you get" iteration through the grid. Thanks. Prithvi

Administrator [Syncfusion]
Replied On April 26, 2005 04:32 PM

Hi Prithvi, I updated your Direct-Trac incident. Here is some code to get the details. If the display element is a nested table, you can access the NestedTable''s display elements. private void button1_Click(object sender, System.EventArgs e) { for(int i = 0; i < this.gridGroupingControl1.Table.DisplayElements.Count; i++) { Element el = this.gridGroupingControl1.Table.DisplayElements[i]; if(el.Kind == DisplayElementKind.NestedTable) { GridNestedTable nt = (GridNestedTable) el; foreach(Element el1 in nt.ChildTable.NestedDisplayElements) { System.Diagnostics.Trace.WriteLine(el1); } i += (nt.ChildTable.NestedDisplayElements.Count - 1); } else { System.Diagnostics.Trace.WriteLine(el); } } } GGC_18197.zip Best regards, Jay N

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;