The output from the following code, in a ComputedText element, is confusing me:
@Text(@Elements(editDate)) + ": " + editDate[1] + @NewLine +
@Text(@If(@Elements(editDate) <= 0)) + @NewLine +
@Text(@If(@Trim(editDate[1]) = “”))
The output is as follows:
13: 11/6/2007 11:43:09 AM
0
0
In other words, there are thirteen elements, the first one has a value of 11/6/7.
But when I test the count of values for less than 1, it returns false; and if I test the first value for existence, the test returns false. These tests should return TRUE!
This shouldn’t be happening. What’s going wrong?
Thanks,
-Jeff
PS Here’s what I’m really trying to do:
count := @Elements(editDate);
@If(count <= 0 | @Trim(editDate[1]) = “”; @Return(“”); “”);
@For(i := 1; i <= count; i := i + 1;
HTML := HTML + "<TR ><TD VALIGN=TOP >" + editDate[i] + "</TD>";
HTML := HTML + "<TD VALIGN=TOP >" + editName[i] + "</TD>";
HTML := HTML + "<TD VALIGN=TOP>" + action[i] + "</TD>";
HTML := HTML + "<TD VALIGN=TOP>" + oldVal[i] + "</TD>";
HTML := HTML + "<TD VALIGN=TOP>" + newVal[i] + "</TD>";
HTML := HTML + "</TR>" + @NewLine);