Error in formula

Hi There, is anyone able to explain what is wrong in this formula
if(and({CR}<>0;{VA}<>0);{VA}/{CR};0)
when CR or VA is 0 then i have an error (One of the parameter is not valid) however I’m expecting the formula result to be 0
on an other hand this one give the right result
if(and({CR}<>0;{VA}<>0);1;0)
CR and VA are formulas column
Thanks for your help

Found the clue … use if(and({CR}<>0;{VA}<>0);DIVIDE({VA};{CR});0)