y axis label formatting

TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
Post Reply
Neelam
Advanced
Posts: 193
Joined: Fri Jun 08, 2007 12:00 am

y axis label formatting

Post by Neelam » Wed Jul 08, 2009 11:50 am

Hi
I have a bar chart whose y axis labels are currently showing upto one decimal palce. i want them to show upto 2 decimal places. How to do that?Tahnks .

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

Re: y axis label formatting

Post by Yeray » Wed Jul 08, 2009 12:30 pm

Hi shikha,

You have to do this to have two decimals at maximum:

Code: Select all

tChart1.Axes.Left.Labels.ValueFormat = "#.##";
Ans this to force two decimals:

Code: Select all

tChart1.Axes.Left.Labels.ValueFormat = "#.00";
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

Neelam
Advanced
Posts: 193
Joined: Fri Jun 08, 2007 12:00 am

Re: y axis label formatting

Post by Neelam » Thu Sep 03, 2009 5:10 am

Thanks.
whts the difference between these-
tcStraAssessRC.Axes.Left.Labels.ValueFormat = "#.##"

and

tcStraAssessRC.Axes.Left.Labels.ValueFormat = "0.00"

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

Re: y axis label formatting

Post by Narcís » Thu Sep 03, 2009 8:30 am

Hi shikha,

Please read MSDN's Custom Numeric Format Strings entry for complete information.
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

Post Reply