This is a migrated thread and some comments may be shown as answers.

how to set a label format with the current cultureinfo?

1 Answer 62 Views
Gauge
This is a migrated thread and some comments may be shown as answers.
Marcelo
Top achievements
Rank 1
Marcelo asked on 21 Jun 2011, 01:12 PM
Hi guys,

I'm trying to set the format of the Guge, but I'am not having much luck...

My application uses a "pt-BR" culture-info (set on the CurrentThread and the web.config)...
On "pt-BR" culture-info, CurrencyDecimalSeparator and CurrencyGroupSeparator are "," and "."


this.radialScale.Label.Format = "{0:C2}";

give me "$ 10,000.00"  and what I want is "R$ 10.000,00"

So, there's a way to achieve this?

1 Answer, 1 is accepted

Sort by
0
Accepted
Andrey
Telerik team
answered on 23 Jun 2011, 12:24 PM
Hello Marcelo,

You can specify the Language property value in XAML code or from the code behind to "pt-BR" to get the language specific Label Format. The property is inherited by children elements. So, you can specify it for MainPage class or directly for the radial scale.
this.Language = System.Windows.Markup.XmlLanguage.GetLanguage("pt-BR");

this.radialScale.Language = System.Windows.Markup.XmlLanguage.GetLanguage("pt-BR");

Greetings,
Andrey Murzov
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Tags
Gauge
Asked by
Marcelo
Top achievements
Rank 1
Answers by
Andrey
Telerik team
Share this question
or