How to change decimal to currency by using script ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-15-2022 07:30 AM
How to change decimal to currency by using script ?
Like
3456 to 3,456
- Labels:
-
Scripting and Coding
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-15-2022 07:44 AM
g_form.setValue('currency field name', currency_code + ';' + currency_amount);
currency_code is the code of the currency example $ - USD currency_amount is the decimal value.
Mark correct and helpful
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-15-2022 08:03 AM
Hello
Thank you for response
it is showing Like this USD;2569
I want the convert decimal number to currency
250000 this is to be convert like 2,50,000
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-20-2025 03:50 PM
that "currency_code" + ';' + currency_amount really does work on my situation, thanks.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-15-2022 08:03 AM
So depending on what/why/when then google is your friend.
https://sebhastian.com/javascript-format-number-commas/
Otherwise if you are trying to set a form value Saiganeshraja has you covered.