Hi, I have (this time) the problem that regardless of how I try to formulate an <@if> tag expression I get the error -18:
The action code looks like this: <@assign name="varMaxPicArtistID" value="<@calc expr='@@request$varMaxPicArtistID + 1'>" scope="request"> <@if expr"@@request$varMaxPicArtistID < 10"> <@assign name="varMaxPicArtistID" value="00<@var request$varMaxPicArtistID>" scope="request"> <@elseif expr"@@request$varMaxPicArtistID < 100"> <@assign name="varMaxPicArtistID" value="0<@var request$varMaxPicArtistID>" scope="request"> </@if> The varMaxPicArtistID value is "002" in this example before the first <@assign>. The first <@assign> works ok increasing the var with 1, but then... I originally had the <@if expression comparison based on the length function (len()) of the variable, then on the <@length> tag and last on a comparison of the actual values, all generating the same error. I would understand if the first <@assign> tag would generate an error based on type mismatch in the <@calc> tag (002 + 1) but it seems to handle the conversion ok since the variable is correctly updated to 3 (as shown in the error). ---------------------------------------------------------------------------- ----------------- Error An error occurred while processing your request: File: OrfeoMAadmin.taf Position: Correct_varMaxPicArtistID Class: Internal Main Error Number: -18 Error during expression evaluation. Comparison operator expected in statement [expr3 < 10] Meta Stack Trace: Line Meta Tag 0001 3 0001 <@IF expr"3 < 100"> <@assign name="varMaxPicArtistID" value="0<@var request$varMaxPicArtistID>" scope="request"> </@IF> 0008 <@if expr"3 < 10"> <@assign name="varMaxPicArtistID" value="00<@var request$varMaxPicArtistID>" scope="request"> <@elseif expr"3 < 100"> <@assign name="varMaxPicArtistID" value="0<@var request$varMaxPicArtistID>" scope="request"> </@if> *The meta stack is interpreted top-to-bottom: the top line shows the inner metatag that caused the error. ---------------------------------------------------------------------------- ---- ________________________________________________________________________ TO UNSUBSCRIBE: Go to http://www.witango.com/maillist.taf
