How can I format the number with (.) And (,) Example: $ 1,000,000.00 in Thunkable X
Iβm doing math operations and displaying on a label
Can someone help me? Thanks
How can I format the number with (.) And (,) Example: $ 1,000,000.00 in Thunkable X
Iβm doing math operations and displaying on a label
Can someone help me? Thanks
Hi there,
Here is a sample app that will reformat any number to insert commas as you are talking about.
β10000β will be reformatted to β10,000β, β1000000β will be reformatted to β1,000,000β, etc.
This app will also remove excess zeros from the front of a number, eg. β01β will be reformatted to β1β, β00001110β will be reformatted to β1110β.
This can be removed by removing a block from the βcleanupβ function.
You can add any desired currency symbol by adding to the βjoinβ block in the βformat numberβ function.
You can see a previous tutorial in rounding numbers here.
Let me know if you have any questions about either of these sample apps!
Thanks,
Jane
Hello @jane, can you share your example again? The link is broken!
A post was split to a new topic: Display Custom number formats
Hey @paulovaz72
This is great! Can you share a sample project of this! Would love to move it to the examples/snippets section of the forum!
Sure! Here it is:
Regards,
Paulo Vaz