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.
Syncfusion Feedback

How do I customise how the row headings are rendered on a GridControl

Thread ID:

Created:

Updated:

Platform:

Replies:

70472 Dec 12,2007 12:17 PM UTC Dec 2,2009 06:22 PM UTC Windows Forms 2
loading
Tags: FAQ
Andrew Ormerod
Asked On December 12, 2007 12:17 PM UTC

Hi,

We currently customise the column headings in our Syncfusion.Windows.Forms.Grid.GridControl grid using a GridHeaderCellRenderer.

How do I go about customising how the row heading? (i.e. where the row numbers normal appear)

Thanks,

Andrew


SubhaSheela R [Syncfusion]
Replied On January 3, 2008 12:52 PM UTC

Hi Andrew,

Thank you for using Syncfusion products.

You can customize the row heading using GridHeaderCellRenderer class. But for simple customization like changing the color you can use BaseStylesMap. Please refer the below code snippet to achieve this:

this.gridControl1.Model.BaseStylesMap["Row Header"].StyleInfo.Interior = new BrushInfo(GradientStyle.Vertical, Color.Red, Color.FromArgb(197, 222, 255));

Kindly refer to the link below that illustrates the same:
http://websamples.syncfusion.com/samples/Grid.Windows/F70472/main.htm
Please let me know if you have any other questions.

Regards,
Subhasheela R.



Glenn Jones
Replied On December 2, 2009 06:22 PM UTC

Hi,

I am trying to do something like this, too. I would like to have the headers that correspond to the current cell highlighted. I have a solution, but it only works with ThemesEnabled = false. Is there a theme-friendly way of highlighting a header cell in the grid?

Thanks
Glenn

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.

Warning Icon 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.Close Icon

;