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: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

How to "unset" a GridStyleInfo member (e.g., "BackColor" or "TextColor")?

Thread ID:





34555 Sep 12,2005 07:59 PM UTC Sep 13,2005 01:56 PM UTC WinForms 2
Tags: GridControl
Ken Overton
Asked On September 12, 2005 07:59 PM UTC

I have sets of GridStyleInfo objects that operate as "user styles" -- in various grid event handlers I use GridStyleInfo.ModifyStyle() to apply user styles based on policy. But what if I want to "clear" a parameter (not the whole style) so that it no longer gets added in when I call ModifyStyle()? Right now I''m still clobbering fields when I set them to, e.g., Color.Empty or Color.Transparent. But this problem is not limited to color fields.

Administrator [Syncfusion]
Replied On September 13, 2005 01:19 PM UTC

Hi, You can use the reset methods conditionally in the style object. For eg: For reseting the backcolor the syntax is as follows, style.ResetBackColor(); Regards, Leo.

Ken Overton
Replied On September 13, 2005 01:56 PM UTC

Thanks, that did the trick!


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.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

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