Template question: is it possible to ignore an empty variable?
I have this template to populate #percentread from the runtime chain variable "Current_Page":
Code:
program:
totalpage = $#pagecount;
currentpage = globals(Current_Page=1);
newpercent = round(multiply ((currentpage / totalpage), 100));
Currently, if I leave Current_Page empty, it defaults to 1 and newpercent does math based on that.
Is there a way to instead ignore an empty variable and leave #percentread unmodified?