I am taking an introductory course to IBM iSeries and Rational Developer, and I'm having difficulty compiling one of my RPGLE programs for a lab... Unfortunately, the lab is just a walkthrough of code we are supposed to compile without much explanation, so I have absolutely no clue about what I'm doing....
When I compile my program MARKSRPG.RPGLE, most of my errors say "The Name Or Indicator Is Not Defined"... I don't know what this means, and I'm unable to move ahead to see if what I have coded works thus far.
(UPDATE: I've made corrections to the suggestions, and now I'm getting different errors. "The types of the left and right hand side do not match in the EVAL operation", and "Operands are not compatible with the type of operator.)
The program is broken up into two files: MARKSRPG.RPGLE and MARKSDSP.DSPF. Here is the code for both, but my errors only show up on MARKSRPG.RPGLE
MARKSDSP:
A R RECORD1
A 1 33'Marks Calculator'
A 2 2USER
A 1 2SYSNAME
A 1 72DATE
A 4 24'Test 1:'
A 5 24'Test 2:'
A 6 24'Test 3:'
A 7 24'Labs:'
A 8 24'Exam:'
A TEST1 3 0B 4 32RANGE(0 100)
A TEST2 3 0B 5 32RANGE(0 100)
A TEST3 3 0B 6 32RANGE(0 100)
A LABS 3 0B 7 32RANGE(0 30)
A EXAM 3 0B 8 32RANGE(0 100)
A FIELD T B 2 71
A R RECORD2 CA03(03 'Exit')
A OVERLAY
A 10 23'Tests:'
A 11 18'Final Mark:'
A 12 17'Final Grade:'
A TESTOVRLL 3 0O 10 30
A NUMGRADE 3 0O 11 30
A GRADE 2X O 12 30
A 13 17'F3 - Exit'
MARKSRPG:
FMARKSDSP CF E WORKSTN
DLETGRADE S 1A
DTESTOVRLL S 3A
/FREE
EXFMT RECORD1;
DOW NOT(*IN03);
EXSR GETGRADE;
WRITE RECORD1;
EXFMT RECORD2;
IF *IN03= *OFF;
EXSR CLEARMARKS;
EXFMT RECORD1;
ENDIF;
ENDDO;
*INLR = *ON;
RETURN;
BEGSR GETGRADE;
LETGRADE = 'F';
TESTOVRLL = (TEST1 + TEST2 + TEST3)/3;
NUMGRADE = (TESTOVRLL/100*.30) + LABS +(EXAM/100*.35);
ENDSR;
BEGSR CLEARMARKS;
TEST1 = 0;
TEST2 = 0;
TEST3 = 0;
LABS = 0;
EXAM = 0;
TESTOVRLL = 0;
ENDSR;
/END-FREE
If you know of any useful resources for learning RPGLE and CLLE I'd appreciated it, and
any additional insight and help would be great too!
Thanks.