/* REXX ------------------------------------------------------------- */ /* Macro: BODY */ /* Syntax: BODY */ /* Parameter: none */ /* Function: counts the number of lines in the )BODY section of */ /* an ISPF-Panel. */ /* Author: Norbert Haas */ /* Remark: See macro AREA. */ /* ------------------------------------------------------------------ */ "ISREDIT MACRO" "ISREDIT FIND FIRST ')BODY' 1" IF rc = 0 THEN DO "ISREDIT (z1) = LINENUM .ZCSR" "ISREDIT FIND NEXT ')' 1" IF rc = 0 THEN DO "ISREDIT (z2) = LINENUM .ZCSR" anz = z2 - z1 - 1 "ISREDIT (panel) = MEMBER" zedsmsg = 'BODY' anz 'lines' zedlmsg = 'Panel' panel 'has' anz 'line in the BODY-Section.' "ISPEXEC SETMSG MSG(isrz000)" "ISREDIT FIND FIRST ')BODY' 1" END ELSE DO zedsmsg = 'Error (END missing)' zedlmsg = 'No )END-Section found in this panel.' "ISPEXEC SETMSG MSG(isrz001)" END END ELSE DO zedsmsg = 'Error (BODY missing)' zedlmsg = 'No )BODY-Section found in this panel.' "ISPEXEC SETMSG MSG(isrz001)" END EXIT