Last one, I promise!!
Can either of you help with the below:
“$”+ num = (thisComp.layer(“% P&L”).effect(“Slider Control”)(“Slider”)*10000000).toFixed(0);
function addCommas(x) {
return x.toString().replace(/\B(?=(\d{3})+(?!\d))/g, “,”);
}
addCommas(num)
Basically I have a text layer looking at a slider, multiplying that number by 10,000,000, keeping it to two decimal places and adding in commas….however I want a dollar sign at the start.
Searching around I came up with the above but the $ symbol is not showing.
As always your help is appreciated.