Unable to change the panel color

TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
Post Reply
mcpang
Newbie
Newbie
Posts: 15
Joined: Wed Mar 31, 2010 12:00 am

Unable to change the panel color

Post by mcpang » Tue Sep 07, 2010 1:55 am

Hi,

I am unable to change the panel color using the following code:

tChart1.Panel.Color = Color.Red;

The above code is working fine in TeeChart v2005, but fail to work in TeeChart v2010.

Please help.

Thanks.

Yeray
Site Admin
Site Admin
Posts: 9601
Joined: Tue Dec 05, 2006 12:00 am
Location: Girona, Catalonia
Contact:

Re: Unable to change the panel color

Post by Yeray » Tue Sep 07, 2010 4:25 pm

Hi mcpang,

I'm not sure what do you mean with TeeChart v2005.
Anyway, in TeeChart v2010 there is the panel's gradient activated by default. Try deactivating it:

Code: Select all

tChart1.Panel.Gradient.Visible = false;
Best Regards,
ImageYeray Alonso
Development & Support
Steema Software
Av. Montilivi 33, 17003 Girona, Catalonia (SP)
Image Image Image Image Image Image Please read our Bug Fixing Policy

mcpang
Newbie
Newbie
Posts: 15
Joined: Wed Mar 31, 2010 12:00 am

Re: Unable to change the panel color

Post by mcpang » Wed Sep 08, 2010 2:16 am

I have tried setting the panel's gradient to false. But it didn't help.

I have also tried the following code, but it still don't work.
tChart1.Panel.Brush.Color = Color.Red

Sorry, actually TeeChart2005 refers to TeeChartv2 for VS NET 2005.

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Re: Unable to change the panel color

Post by Narcís » Wed Sep 08, 2010 1:55 pm

Hi mcpang,

Code below sets chart panel color to red using latest v2010 release. Can you please check if this works fine at your end and attach a simple example project we can run "as-is" to reproduce the problem if it still persists?

Code: Select all

            tChart1.Clear();
            tChart1.Panel.Color = Color.Red;
            tChart1.Panel.Gradient.Visible = false;
Thanks in advance.
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

mcpang
Newbie
Newbie
Posts: 15
Joined: Wed Mar 31, 2010 12:00 am

Re: Unable to change the panel color

Post by mcpang » Thu Sep 09, 2010 3:19 am

Thanks for the reply.
Manage to get it works by doing the code provided by you.

Post Reply