How to change color of scale display.

TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
Post Reply
biji
Newbie
Newbie
Posts: 35
Joined: Wed Jul 02, 2008 12:00 am

How to change color of scale display.

Post by biji » Thu Mar 07, 2013 1:20 pm

Hi,
I am using TeeChart for.net v3 version. I am creating GUI in C#. I am able to create multiple y-axis based on incoming data from some unit. I am creating separate axis with different color for each axis. The scale on each axis is displaying with black color. I want to display the scale also with the same color as the axis. You can see the image how it is now and how i want please look into this question.http://stackoverflow.com/questions/1519 ... n-teechart. If this was not enough then please ask me for more information.

Sandra
Site Admin
Site Admin
Posts: 3132
Joined: Fri Nov 07, 2008 12:00 am

Re: How to change color of scale display.

Post by Sandra » Thu Mar 07, 2013 4:34 pm

Hello vera,

If you want modify the color of labels you need change font color property of labels because letters have the same color of Axes. You can do something as next code:

Code: Select all

axis.Labels.Font.Color = axis.AxisPen.Color; 
axis.Ticks.Color = axis.AxisPen.Color; 
axis.MinorTicks.Color = axis.AxisPen.Color; 
Could you tell us if previous lines of code works in your end? I answer, too, in the stack overflow link: http://stackoverflow.com/questions/1519 ... n-teechart.

Thanks,
Best Regards,
Sandra Pazos / 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

biji
Newbie
Newbie
Posts: 35
Joined: Wed Jul 02, 2008 12:00 am

Re: How to change color of scale display.

Post by biji » Thu Mar 07, 2013 4:57 pm

Hi Sandra,

Thank you very much for your replay, The above code of lines working perfectly to display labels and axis with same color. I need one more small help what should i need to do to display my labels(scales)horizontally. because now i am displaying scale vertically and its taking more space if i have more axis. I want to display the scale as shown in the second image from stack overflow question.

Could you tell us if previous lines of code works in your end?
I have tried your code separately to understand properly its working but in my case i am doing with other way.

Sandra
Site Admin
Site Admin
Posts: 3132
Joined: Fri Nov 07, 2008 12:00 am

Re: How to change color of scale display.

Post by Sandra » Fri Mar 08, 2013 12:22 pm

Hello veera,

To change the angle of scale (labels) you only need change the property Angle of labels as do in next lines of code:

Code: Select all

 axis.Axes.Custom[i].Labels.Angle = 90;
Thanks,
Best Regards,
Sandra Pazos / 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

biji
Newbie
Newbie
Posts: 35
Joined: Wed Jul 02, 2008 12:00 am

Re: How to change color of scale display.

Post by biji » Mon Mar 11, 2013 2:45 pm

Hi Sandra,

Thank you very much for your help, That is what i need. Its working perfect. 1000 thanks.

Regards,
Veera.

Post Reply