cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
anotherlama
Level: Powered On

Currency Formatting Form

Hello everyone,

 

I am having a form of type "New". I have different number fields that I tried to currency format (I am located in Germany). In order to do so, I used a variable "varXY" as Default Value of the DataCardValue. The on change property is set to the following:

Set(
varXY;
Text(
Value(DataCardValue_XY.Text);
"[$-de-DE]€ ###.##0"
)
)

1000 is formatted like this: € 1.000 -> just the way I want it.
However, if someone opens the app who has not set his/her browser settings to German, but for exampe english, the formatting changes to $ 1,000. I learned that I need to overwrite the language settings by adding a third parameter to the function. I tried the following:

Set(
varCostCrew_CreateRequest;
Text(
Value(DataCardValue_CostCrew.Text);
"[$-de-DE]€ #.0" ;"de-DE"
)
)



Now, after onChange fired, no value is shown anymore. However, in the editor I see that the formula evaluates to € 1.000, just like I want it. I have no idea why it is not showing the new value. I think it is probably because I use the Text() function in a number field. However, it is working perfectly when not using the new parameter/language tag, so that is probably not the problem here. Any ideas what to do? As I have a big number of fields that I all have to change (probably causing many bugs), it would be optimal if I did not had to change the format/type of the data card value field.

Thanks a lot for your help in advance. Really appreciate it! 

UPDATE: I changed the second formula above. I did not copy it correctly when creating the post.

2 REPLIES 2
v-siky-msft
Level 10

Re: Currency Formatting Form

Hi @anotherlama ,

 

Modify as below:

 

 

Set(
varCostCrew_CreateRequest;
Text(
Value(DataCardValue_CostCrew.Text);
"[$-de-DE]€ #.0" ;"de-DE"
)
)

 

 

Best regards,

Sik

anotherlama
Level: Powered On

Re: Currency Formatting Form

Dear @v-siky-msft ,

 

I am very sorry! I just realized this is exactly what I tried. I made a mistake when I recreated the formula for this post. The problem with the default value not being displayed appeared when using exactly your formula. Any idea what to do?

Helpful resources

Announcements
thirdimage

Power Apps Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

SecondImage

Difinity Conference

The largest Power BI, Power Platform, and Data conference in New Zealand

Top Kudoed Authors (Last 30 Days)
Users online (3,765)