Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Next up in the FabCon + SQLCon recap series: The roadmap for Microsoft SQL and Maximizing Developer experiences in Fabric. All sessions are available on-demand after the live show. Register now

Reply
Martin18
New Member

valueFormatter ignores culture for displayUnit

Hi all,
 
I'm having little trouble with valueFormatter as I can't get it format my values as expected in terms of the unit abbreviation and the given culture. Even though it produces the correct decimal character (comma), the unit abbreviation still looks like for the default culture ("en-US").
 
Here's what I've done: 
 
visual.ts:
 
 
import valueFormatter = powerbi.extensibility.utils.formatting.valueFormatter;
...
let formatterOptions : utils.formatting.ValueFormatterOptions = {
value: 1000,
precision: 1,
cultureSelector: options.host.locale // "de-DE"
};
let formatter = valueFormatter.create(formatterOptions);
let v = formatter.format(2500); // gives 2,5K and not 2,5 Tsd. 😞
pbiviz.json:
 
... 
"externalJS": [ "node_modules/globalize/lib/globalize.js", "node_modules/globalize/lib/cultures/globalize.cultures.js",
...
Is there anything wrong with my code?
 
Any help will be appreciated. Thank you.
1 ACCEPTED SOLUTION
v-viig
Community Champion
Community Champion

It looks like postfix has not been localized for all of languages.

 

Please create a new bug in GitHub: https://github.com/Microsoft/powerbi-visuals-utils-formattingutils

 

Ignat Vilesov,

Software Engineer

 

Microsoft Power BI Custom Visuals

pbicvsupport@microsoft.com

View solution in original post

3 REPLIES 3
v-viig
Community Champion
Community Champion

It looks like postfix has not been localized for all of languages.

 

Please create a new bug in GitHub: https://github.com/Microsoft/powerbi-visuals-utils-formattingutils

 

Ignat Vilesov,

Software Engineer

 

Microsoft Power BI Custom Visuals

pbicvsupport@microsoft.com

I'm using formatting utils with new powerbi-visual-tools 3 (beta) and get some behavior. When this bug will fix?

v-viig
Community Champion
Community Champion

Did you face exactly the same issue?

 

Ignat Vilesov,

Software Engineer

 

Microsoft Power BI Custom Visuals

pbicvsupport@microsoft.com

Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.