Marks format

TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
Post Reply
Hermes
Newbie
Newbie
Posts: 5
Joined: Wed May 23, 2018 12:00 am

Marks format

Post by Hermes » Thu Jan 10, 2019 10:18 pm

Is there any way to format the mark's number, qty of decimals and locale (to get client locale in case of web app)?

Thank you in advance

Christopher
Guru
Posts: 1603
Joined: Fri Nov 15, 2002 12:00 am

Re: Marks format

Post by Christopher » Mon Jan 14, 2019 8:07 am

Hello,

yes, you can use the Series.ValueFormat property, e.g.

Code: Select all

		private void InitializeChart()
		{
			Bar bar = new Bar(tChart1.Chart);

			bar.FillSampleValues();
			bar.ValueFormat = "0.00";
		}
Best Regards,
Christopher Ireland / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Instructions - How to post in this forum

Hermes
Newbie
Newbie
Posts: 5
Joined: Wed May 23, 2018 12:00 am

Re: Marks format

Post by Hermes » Tue Jan 15, 2019 2:55 pm

Hi,
with you example i can set decimal qty, but what locale it takes?
Can I set the locale of the control or must I change the culture Info of the thread? (I need to set the client Culture Info in a webforms aplication to show numbers).

Thank you

Christopher
Guru
Posts: 1603
Joined: Fri Nov 15, 2002 12:00 am

Re: Marks format

Post by Christopher » Tue Jan 15, 2019 3:19 pm

Hermes wrote:
Tue Jan 15, 2019 2:55 pm
with you example i can set decimal qty, but what locale it takes?
Can I set the locale of the control or must I change the culture Info of the thread? (I need to set the client Culture Info in a webforms aplication to show numbers).
TeeChart is a standard .NET control, and as such I believe the only way is to change the locale of the thread. I don't think it is possible to change the locale of only a single .NET control.
Best Regards,
Christopher Ireland / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Instructions - How to post in this forum

Hermes
Newbie
Newbie
Posts: 5
Joined: Wed May 23, 2018 12:00 am

Re: Marks format

Post by Hermes » Tue Jan 15, 2019 6:55 pm

Hi,
Regardless the .NET controls in general, assuming that on the server I have Spanish and a web client connects with English locale (request.UserLanguages [0] ), if I change the locale of the thread where I am creating the chart, will it be shown with the numerical format of English?

Regards

Christopher
Guru
Posts: 1603
Joined: Fri Nov 15, 2002 12:00 am

Re: Marks format

Post by Christopher » Wed Jan 16, 2019 11:13 am

Hello,
Hermes wrote:
Tue Jan 15, 2019 6:55 pm
if I change the locale of the thread where I am creating the chart, will it be shown with the numerical format of English?
Yes, I believe it will.
Best Regards,
Christopher Ireland / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Instructions - How to post in this forum

Post Reply