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

Hierarchical grid - Parent rows with no rows

Hi,
i have a hierarchical grid (two levels: parent rows and child rows).
Could i mark (with a color or otherelse) parent rows that haven't child rows ?
Thanks in advance
Piermaria

1 Reply

SS Satheeskumar S Syncfusion Team April 10, 2014 11:56 AM UTC

Hi Piermaria,

Thanks for your interest in Syncfusion Products.

 

We are glad to let you know that your requirement “Apply styles to Parent Grid” Can be achieved. We have used RowDataBound Event to apply the styles tp parent grid rows.

Please refer the below code snippet.

void ggc_RowDataBound(object sender, RowDataBoundEventArgs e)

{

            if (e.Element.Kind == DisplayElementKind.Record && e.Element.ChildTableGroupLevel == 0)

            {

                        e.Row.BackColor = Color.Green;

            }

}

 

For your convenience we have attached the sample. Could you please let us know if it was helpful.

 

Please let us know if you need any further assistance.

Regards,

Satheeskumar S


Attachment: Grouping_IssueData_Import_c2df8146.zip

Loader.
Live Chat Icon For mobile
Up arrow icon