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

Formatting DataCardValue number

In my DetailScreen form, I would like to format the DataCardValue to display a format of 55,000 instead of 55000.

How is this done? This code does not work

 

Text(Parent.Default,"[$-en-US]#,##0")

 

Thanks

1 ACCEPTED SOLUTION

Accepted Solutions
PowerApps Staff CarlosFigueira
PowerApps Staff

Re: Formatting DataCardValue number

There is currently a bug where the Text function inside a data card is not working correctly - it should be fixed in an upcoming release.

 

As a workaround, you can change the value of the data card's Default property instead of the control itself. So in your case the DataCardValue Text property would go back to 'Parent.Default', but if you select the card, you should be able to wrap the Default property in the Text function, something along the lines of

Text(ThisItem.ColumnName,"[$-en-US]#,##0")
6 REPLIES 6
PowerApps Staff CarlosFigueira
PowerApps Staff

Re: Formatting DataCardValue number

There is currently a bug where the Text function inside a data card is not working correctly - it should be fixed in an upcoming release.

 

As a workaround, you can change the value of the data card's Default property instead of the control itself. So in your case the DataCardValue Text property would go back to 'Parent.Default', but if you select the card, you should be able to wrap the Default property in the Text function, something along the lines of

Text(ThisItem.ColumnName,"[$-en-US]#,##0")
lauriewheeler
Level: Powered On

Re: Formatting DataCardValue number

This didn't work either way for us. Any news on when it will be fixed?
PeterDonohue
Level: Powered On

Re: Formatting DataCardValue number

Why is this marked as a solution when it clearly says it's not, and asks for an update. Again, this should be pretty straight forward right? I'm getting 13 decimal places, even when my source is set to 2 decimal places?

lauriewheeler
Level: Powered On

Re: Formatting DataCardValue number

The formula does work, but doesn't work in all situations.  I ended up re-doing my solution as just a 'powerapp' form not a Canvas app, then the formula worked.

Steven_Ross_Lee
Level: Powered On

Re: Formatting DataCardValue number

Thanks Carlos, but I don't believe this is fixed yet. I can't get the Text function to work whether I implement it at the data card level or in the data card textbox.
I did get it to work once only for a data card that somehow got created without a MaxLength property.

/Steve
lauriewheeler
Level: Powered On

Re: Formatting DataCardValue number

To my knowledge this is not fixed either.  The only option I thought of to try was to push the value to a label and apply the Text function to the label.. then placing the label overtop of the control, but it doing so means extra logic for visibility of edit vs view and lots of extra work.