I would like to convert NaN value to 0 when I do calculation in weweb.
Which function I should use ?
Many thx for the help
I would like to convert NaN value to 0 when I do calculation in weweb.
Which function I should use ?
Many thx for the help
Wrap if with
if(isNaN(myResult), "0 %", myResult + " %")
IsNaN is not recognized as a function by weweb.
Because we didn’t make it a formula but it’s not an issue as it is a valid javascript function, it should work, what do you get ?
I guess your field is a “Number” field, right? You must remove the %-sign in Alexis’ solution. Then it should work.
It’s working ! Thx all