Expand my Community achievements bar.

Radically easy to access on brand approved content for distribution and omnichannel performant delivery. AEM Assets Content Hub and Dynamic Media with OpenAPI capabilities is now GA.

Please Help FormCalc syntax error..

Avatar

Level 1

form1.#subform[0].Table2.FooterRow.total::calculate - (FormCalc, client)

(((sum(Table2.row[

*].total)

if(Table2.FooterRow.total>0)

then(+15)endif)))

Error: syntax error near token 'if' on line 2 colum 2

Ive played with it so many times, now I have no idea what ive done and not done..

ugh.. ive spent way to much time on this

What I want if the calculation returns a value other than 0 to add the 15.. if its 0 dont add the 15..

Seems simple enough..

Thanks

1 Reply

Avatar

Level 10

Try like this..

if(Table2.FooterRow.total ne 0)then

     $.rawValue = $.rawValue +15;

endif

I did not understand the previous line in your code..So I am placing the following with my own assumptions.

if (sum(Table2.row[

*].total) >0) then

     $.rawValue = $.rawValue +15;

endif

Thanks

Srini