Referring to an array index in a label BRANCH

size = sizeOf(myRecList);
/myRecList[%size%-1]/field1:BRANCH (evaluate labels = true)
ABC:SEQUENCE
BLAH…BLAH…BLAH…

I am looking at the value of the field1 in the last index of myRecList. This does not seem to work! Any help appreciated.

thanks
ck

Evaluate labels = true specifies to evaluate the labels of child steps, not the label of the branch statement itself. Also, to refer to an array var, the syntax is %/myRecList[0]%. This prohibits the use of %size% for the index value. You’ll need to use another technique. Try this:

size = sizeOf(myRecList);
size = subtractInts(size, 1);
rec = getRecordListItem(size);
BRANCH: /rec/field1 (eval labels = false)
…ABC:SEQUENCE
blah, blah, blah

Try this:
size = sizeOf(myRecList);
MAP: variable1 = /myRecList[%size%-1]/field1
variable1:BRANCH (evaluate labels = true)
variable1 == “ABC”:SEQUENCE
BLAH…BLAH…BLAH…

Thanks