* PICGRADE.CMD

STORE F TO DONE
ERASE
DO WHILE .NOT. DONE
    STORE "  " TO MGVAR
    @  11,15 SAY "                                                   "
    @  10,15 SAY "Record T(est), P(roject) or A(ssignment)----> ?  " ;
         GET MGVAR PICT "!"
    READ
    @ 10,15 SAY "                                                    "
    IF MGVAR = "A" .OR. MGVAR = "A"
        STORE "ASN" TO MFIELD
    ELSE
        IF MGVAR = "T" .OR. MGVAR = "t"
            STORE "TEST" TO MFIELD
        ELSE
            IF MGVAR = "P" .OR. MGVAR = "p"
                STORE "PROJ" TO MFIELD
            ELSE
               @ 11,20 SAY "Type an uppercase A or T please"
               LOOP
            ENDIF
        ENDIF
    ENDIF
    STORE T TO DONE
ENDDO
@ 11,20 SAY "                                                      "
STORE F TO DONE
DO WHILE .NOT. DONE
    RELEASE MGVAR
    STORE "   " TO MGVAR
    IF MFIELD = "TEST"
        @ 10,20 SAY "CHOOSE TEST NUMBER BETWEEN 1 AND 5 ---->  ";
            GET MGVAR
        READ
        @ 10,20 SAY "                                             "
        IF VAL(MGVAR) > 5
            @ 11,20 SAY "NO SUCH TEST!"
            LOOP
        ENDIF
        STORE "0" + STR(VAL(MGVAR),1) TO MNU
        STORE T TO DONE
    ENDIF

    IF MFIELD = "PROJ"
        @ 10,20 SAY "CHOOSE PROJECT # BETWEEN 1 AND 5 ---->  ";
             GET MGVAR
        READ
        @ 10,20 SAY "                                             "
        IF VAL(MGVAR) > 5
            @ 11,20 SAY "NO SUCH PROJECT!"
            LOOP
        ENDIF
        STORE "0" + STR(VAL(MGVAR),1) TO MNU
        STORE T TO DONE
    ENDIF

    IF MFIELD = "ASN"
        @ 10,20 SAY "CHOOSE ASSIGNMENMENT # BETWEEN 1 AND 15 ---->  ";
            GET MGVAR
        READ
        @ 10,20 SAY "                                               "
        IF VAL(MGVAR) > 15
            @ 11,20 SAY "NO SUCH ASSIGNMENT! "
            LOOP
        ENDIF
        IF VAL(MGVAR) > 9
            STORE STR(VAL(MGVAR),2) TO MNU
        ELSE
            STORE "0" + STR(VAL(MGVAR),1) TO MNU
        ENDIF
        STORE T TO DONE
    ENDIF
ENDDO
RETURN

               LOOP
            ENDIF
        ENDIF
    ENDIF
    STORE T TO DONE
ENDDO
@ 11,20 SAY "                                                      "
STORE F TO DONE
DO WHILE .NOT. DONE
    RELEASE MGVAR
    STORE "   " TO MGVAR
    IF MFIELD = "TEST"
        @ 10,20 SAY "CHOOSE TEST NUMBER BETWEEN 1 AND 5. ";
            GET MGVAR
