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

How do I get the themed TabPageExt BackColor

Thread ID:





3288 Mar 11,2003 07:52 PM UTC Aug 26,2003 01:14 PM UTC WinForms 10
Tags: Tools
Administrator [Syncfusion]
Asked On March 11, 2003 07:52 PM UTC

Hi, I have a TabControlExt with Themes Enabled. I added couple of Tab Pages to it. To one of the pages I added a GroupBox and couple of Labels. TabPage is coming up white. But the GroupBoxes and labels are coming up Grey (Color.Control). When themes are enabled, TabPageExt is ignoring the BackColor (which is fine) and is drawing white (themed drawing) bg color. I want to set my GroupBoxes and labels back color also white. How do I get this themed BackColor? thanks, - Reddy

Ramesh Praveen [Syncfusion]
Replied On March 13, 2003 05:57 PM UTC

Reddy, When themed drawing is enabled in the tabpages, I suppose you want your group box to be drawn transparent? Then try setting the group boxes backcolor to transparent. There are some issues with certain controls not getting drawn transparently when on a tab page, which we are currently working on. Regards, Praveen Ramesh

Administrator [Syncfusion]
Replied On May 23, 2003 08:55 AM UTC

Hi Praveen, will this be fixed in version 1.6? Sincerely, Kenneth

Ramesh Praveen [Syncfusion]
Replied On May 28, 2003 03:33 PM UTC

Yes, the tabcontrol in 1.6 will support transparent backgrounds in it's child controls when the tab is themed. -Praveen

Administrator [Syncfusion]
Replied On July 1, 2003 09:41 AM UTC

I just downloaded version 1.6 and when I add a UserControl-object a get a runtime-error, if I set this object's BackColor to Color.Transparent... I guess this is only an issue with a UserControl-object - is there another class I can use instead? I was thinking a Panel, but the I loose design-time GUI...

Ramesh Praveen [Syncfusion]
Replied On July 1, 2003 03:23 PM UTC

Kenneth, In your user control do this: this.SetStyle(ControlStyle.SupportsTransparentBackColor, true); then the control should accept transparent BC. Regards, Praveen

Administrator [Syncfusion]
Replied On July 2, 2003 04:29 AM UTC

Sorry, but that doesn't seem to work for me... I can't see any difference whether or not I include... this.SetStyle(ControlStyles.SupportsTransparentBackColor, true); ...on the UserControl's InitializeComponent-method.

Ramesh Praveen [Syncfusion]
Replied On July 7, 2003 06:57 PM UTC

Kenneth, And then you should set the UserControl's BackColor to Transparent. If this still doesn't work, I am surprised as I do see this work here. Please do double check. Regards, Praveen

Administrator [Syncfusion]
Replied On July 15, 2003 06:48 AM UTC

Thanks!! I forgot: this.BackColor = Color.Transparent; after: this.SetStyle(ControlStyles.SupportsTransparentBackColor, true); My mistake, sorry!

Administrator [Syncfusion]
Replied On August 18, 2003 06:01 PM UTC

Hi, I am still trying to fix this in my code on Windows XP Professional/.NET 1.1. Please run the attached sample. Click between the three tabs and see the problem. First tab has label and checkbox bg color set to transparent. Checkbox1 has white bg for some reason. Second tab has tab page bg color set to transparent. The groupbox does not render properly. Third tab has a panel and a groupbox inside the panel. The panel bg color is set to transparent. GroupBox does not render properly. I want the tabs to have a system look and feel with the contents of the tab without the blue color (frame bg color). Please let me know where and what to fix. thanks, - Reddy

Arun Srinivasan [Syncfusion]
Replied On August 26, 2003 01:14 PM UTC

Hi Reddy, Yes this is a well known problem. Unfortunately, this is a limitation in many of the .net controls, as they can be transparent only in certain modes. This is a problem with the themes support in windows which discussed here: http://www.google.com/groups?hl=en&lr=&ie=UTF-8&oe=UTF-8&threadm=uWYxJGaFDHA.2392%40TK2MSFTNGP09.phx.gbl&rnum=1&prev=/groups%3Fq%3Dflatstyle%2Bpraveen%2Bgroup:*dotnet*%26hl%3Den%26lr%3D%26ie%3DUTF-8%26oe%3DUTF-8%26as_qdr%3Dd%26selm%3DuWYxJGaFDHA.2392%2540TK2MSFTNGP09.phx.gbl%26rnum%3D1 So in tabbed pages your child controls should be set to not use the themed background , instead they should be set to be drawn transparent as themed and transparent is not supported as discussed above. Thanks Arun


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

Live Chat Icon For mobile
Live Chat Icon