I know this has been a common question. But I am still trying to figure it out. I have buttons that perform calculations and the result will show in a text field. I simply want that text field to show as US currency, Right now it will show as "10000.00", I would like it to show as "$10,000.00" I will paste a snippet of some of my code (the calculations), any help will be greatly appreciated.
$w("#text2").text = (dropdown5*dropdown6*text2).toFixed(2).toString();
$w("#text4").text = (dropdown5*dropdown6*text4).toFixed(2).toString();
Thank you in advance for any help.
use:
number.toLocaleString('en-US', { style: 'currency', currency: 'USD' });