Forum Discussion
Currency Formatting
Thank you to all who respond,
My goal is to show the currency symbol for US and Euro when the slicer is selected. The slicer is working correctly but I can't seem to get the correct DAX for formatting the field. My code:
This is where I need help.
FORMAT _Sales
Hi Anonymous
How have you structured your DimCurrencyRates table? Does it include a Format column within it? If not, certainly recommend it. From there, you can incorporate LOOKUPVALUE with CONCATENATE.
Link to an article that explains it in some detail: https://blog.enterprisedna.co/format-currencies-in-power-bi-using-dax/
Hope this helps.
Theo
- Anonymous4 years ago
Theo,
DimCurrencyRates table is shown below.
Hi Anonymous ,
You can try this:-
FORMAT_Sales = SWITCH( SELECTEDVALUE('DimCurrencyRates'[Fullname]), "US Dollar",FORMAT([Converted Sales],"$#,##0"), "EURO",FORMAT([Converted Sales],"€#,##0") )Thanks,
Samarth
3 Replies
- Samarth_18Community Champion
Hi Anonymous ,
You can try this:-
FORMAT_Sales = SWITCH( SELECTEDVALUE('DimCurrencyRates'[Fullname]), "US Dollar",FORMAT([Converted Sales],"$#,##0"), "EURO",FORMAT([Converted Sales],"€#,##0") )Thanks,
Samarth
- TheoCCommunity Champion
Hi Anonymous
How have you structured your DimCurrencyRates table? Does it include a Format column within it? If not, certainly recommend it. From there, you can incorporate LOOKUPVALUE with CONCATENATE.
Link to an article that explains it in some detail: https://blog.enterprisedna.co/format-currencies-in-power-bi-using-dax/
Hope this helps.
Theo
- AnonymousNot applicable
Theo,
DimCurrencyRates table is shown below.