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.

Transparent color for control

Thread ID:

Created:

Updated:

Platform:

Replies:

25307 Feb 24,2005 01:56 AM Feb 24,2005 04:30 AM Windows Forms 1
loading
Tags: GridControl
Administrator [Syncfusion]
Asked On February 24, 2005 01:56 AM

When i choose transparent color from a color edit the framework throws an exception saying that this color is not supported by the control. To solve this i set this.SetStyle(ControlStyles.SupportsTransparentBackColor, true); But even then i get a error...How do i fix this

Administrator [Syncfusion]
Replied On February 24, 2005 04:30 AM

The GridControl has a public property that allows this, this.gridControl1.SupportsTransparentBackColor = true; The GridDataBoundGrid does not. But as indicated, you can derive the GridDataBoundGrid and set a style property in the constructor to enable this. public class MyGridDataBoundGrid : GridDataBoundGrid { public MyGridDataBoundGrid() : base() { this.SetStyle(ControlStyles.SupportsTransparentBackColor, true); } } But if you are trying to use TransparentBackColor in an editing cell control, this is not supported as this control is based on a RichTextBox that does not support transparency.

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.

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.

;