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. (Last updated on : Nov 16th 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

How to get a property from a particular style

Thread ID:

Created:

Updated:

Platform:

Replies:

37305 Nov 18,2005 07:16 PM UTC Nov 30,2005 12:54 AM UTC WinForms 4
loading
Tags: GridControl
Michael Scott
Asked On November 18, 2005 07:16 PM UTC

I''d like to get specific properties from a pre-defined style (like the "BackColor" of the style "Row Header"), so I can set that property to a particular cell. I didn''t find how to access that kind of thing in the PDF file, nor in the MSDN help pages. How do I do that?

Michael Scott
Replied On November 18, 2005 07:24 PM UTC

Or perhaps the better solution is to turn off the Gradient Style for the row/colum header styles.

Administrator [Syncfusion]
Replied On November 18, 2005 11:46 PM UTC

If this is a GridControl (where you can set properties cell by cell), you can use code like this to get the gradient from the row header. this.gridControl1[4,2].Interior = this.gridControl1.BaseStylesMap["Row Header"].StyleInfo.Interior;

Michael Scott
Replied On November 30, 2005 12:17 AM UTC

What I''m looking for is something like : gridControlConfMatrix.RowStyles[rows].Interior.ForeColor = gridControlConfMatrix.RowStyles[rows].Interior.BackColor; or : gridControlConfMatrix.ColStyles[cols].Interior.GradientStyle = "None"; Bottom line - I want a cell to mimic ONLY the background color of a cell with the style "Row Header" or "Col Header" Michael

Administrator [Syncfusion]
Replied On November 30, 2005 12:54 AM UTC

Instead of trying to set the style.Interior property, directly set the style.BackColor property. This should override the previously set Interior property.

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

;