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

GridGroupingControl Column Itration

Hai  

Please anyone can give corresponding code of

foreach (DataGridViewColumn col in dgvTransaction.Columns)
                {
                    if (col.HeaderText.ToUpper() == "PARTY CODE")
                    {
                        ColIndex = col.Index;
                        break;
                    }
                }

for Syncfusion grid grouping control

thanks in advance

1 Reply

PP Praveena P Syncfusion Team October 21, 2013 12:44 PM UTC

Hi Ash,

 

Thank you for using Syncfusion products.

 

For GridGroupingControl  column iteration, make use of GridColumnDescriptor class  and get the grouping control columns  from TableDescriptor.

You can get the index of column using the “ IndexOf”.

 

Please refer the below code:

 

foreach (GridColumnDescriptor col in this.gridGroupingControl1.TableDescriptor.Columns)

            {

                if (col.HeaderText.ToUpper() == "PARTY CODE")

                {

                    ColIndex = this.gridGroupingControl1.TableDescriptor.Columns.IndexOf(col);

                    break;

                }

            }

 

 

Please let me know if you have any concerns.

 

Regards,

Praveena

 


Loader.
Live Chat Icon For mobile
Up arrow icon