This code works with ZERO problems when there is just one table. I am trying to reuse this with a report that uses two tables (one for the header of the report, one for the detail).
It looks for the '**-DIRECTIVE-NEGATIVE' in the user field for the element to apply some custom formatting. However, what it puts out is simply 0.00. I have been able to determine that somehow '**********' is being placed in the toObjProperties.Text property. But when I look at the table itself, it shows proper data. What am I missing?
Here's the code:
lnLines = ALINES(laLines, loFRX.User)
IF lnLines > 0
FOR lnLoopCount = 1 TO lnLines
DO CASE
CASE ALLTRIM(laLines[lnLoopCount]) == '**-DIRECTIVE-NEGATIVE'
TRY
lblnNegative = (VAL(toObjProperties.Text) < 0)
lblnIsNumber = TRUE
CATCH
lblnNegative = FALSE
lblnIsNumber = FALSE
ENDTRY
IF lblnNegative
toObjProperties.Text = '<' + ;
ALLTRIM(;
TRANSFORM(ABS(VAL(toObjProperties.Text)),;
"@R 999,999,999,999,999.99");
) + '>'
toObjProperties.PenRed = 255
toObjProperties.PenGreen = 0
toObjProperties.PenBlue = 0
toObjProperties.Reload = TRUE
ELSE
IF lblnIsNumber
toObjProperties.Text = ALLTRIM(;
TRANSFORM(ABS(VAL(toObjProperties.Text)),;
"@R 999,999,999,999,999.99"))
toObjProperties.Reload = TRUE
ENDIF
ENDIF
ENDCASE
NEXT
ENDIF
TIA
Richard
State of Florida, DCF