I have an expression that is working in animating a percentage based on a slider control.
n=thisComp.layer("Null 1").effect("Pie Slice 2")("Slider")
nRound=Math.round(n*10)/10;
check = nRound % 1
if (check == 0){
"" + nRound + ".0" + "%"
}else{
nRound
}
What I can't figure out is why the "%" only appears when the number is whole and not there constantly? After reading through Dan Ebbert page, he indicates that you can in fact add it (which I thought I did correctly) but only on the whole numbers. When it's animating through the "tenths" the % does not appear.
I'm sure it's something simple, but I can't figure it out.
Thanks for your help.