**************************************************
* RECEIPTS.CMD - V1.00 -
* USED TO ENTER GENERAL RECEIPTS IN
* THE GENERAL JOURNAL.
**************************************************
ERASE
STORE " " TO MANS
ERASE
STORE " " TO MDR:AN
STORE " " TO MCR:AN
STORE " " TO MDR:DESCR
STORE " " TO MCR:DESCR
STORE " " TO MDATE
@ 2,5 SAY "NEXT RECORD:"
@ 2,20 SAY MREC
  ACCEPT "Enter DATE OF TRANSACTION (MM/DD/YY) <CR>" TO MDATE
DO WHILE MDR:AN = " "
@ 4,0 SAY " "
******************** ENTER DEBIT DATA *************
DO CASE
  CASE MSELADD = "1"
    ACCEPT "Enter ACCOUNT NUMBER to DEBIT A/N <CR> " TO MDR:AN
  CASE MSELADD = "2"
    ACCEPT "Enter account PAID TO by CHECK A/N <CR> " TO MDR:AN
  CASE MSELADD = "3"
    DO SECTICKS
    RETURN
  CASE MSELADD = "4"
    ACCEPT "Enter GASOLINE EXPENSE A/N <CR> " TO MDR:AN
  CASE MSELADD = "5"
    DO PAYSTUB
    ERASE
    IF MANS = "N"
      @ 10,10 SAY "ENTER MORE RECEIPTS? (Y/N) <CR>"
      WAIT TO MANS
      IF MANS = "y"
        STORE "Y" TO MANS
      ENDIF
    ENDIF
    RETURN
  CASE MSELADD = "6"
    ACCEPT "Enter PURCHASE or EXPENSE A/N <CR> " TO MDR:AN
  CASE MSELADD = "7"
    ACCEPT "Enter CASH PURCHASE A/N <CR> " TO MDR:AN
  CASE MSELADD = "8"
    STORE "N" TO MANS
    RETURN
ENDCASE
***************************************************
  USE ANCHART
  LOCATE FOR AN = MDR:AN
  IF AN = MDR:AN
    STORE DESCR TO MDR:DESCR
  ENDIF
  IF MDR:DESCR = " "
@ 6,0 SAY "ACCOUNT ERROR"
    STORE " " TO MDR:AN
    STORE " " TO MDR:DESCR
    ? CHR(07)
  ENDIF
LOOP
ENDDO
@ 6,0 SAY "             "
@ 6,0 SAY MDR:DESCR
@ 7,0 SAY " "
INPUT "AMOUNT XXXX.XX <CR>       " TO MAMT
STORE MAMT TO MDR:AMT
STORE MAMT TO MCR:AMT
@ 9,0 SAY " "
******************* ENTER CREDIT DATA *************
DO WHILE MCR:AN = " "
@ 9,0 SAY " "
DO CASE
  CASE MSELADD = "1"
    ACCEPT "Enter ACCOUNT NUMBER to CREDIT A/N <CR> " TO MCR:AN
  CASE MSELADD = "2"
    ACCEPT "Enter CHECKING ACCOUNT A/N <CR> " TO MCR:AN
  CASE MSELADD = "4"
    ACCEPT "Enter GAS CREDIT CARD OR CASH A/N <CR> " TO MCR:AN
  CASE MSELADD = "6"
    ACCEPT "Enter CREDIT CARD A/N <CR> " TO MCR:AN
  CASE MSELADD = "7"
    ACCEPT "Enter CASH A/N <CR> " TO MCR:AN
ENDCASE
***************************************************
  USE ANCHART
  LOCATE FOR AN = MCR:AN
  IF AN = MCR:AN
    STORE DESCR TO MCR:DESCR
  ENDIF
  IF MCR:DESCR = " "
@ 11,0 SAY "ACCOUNT ERROR"
    STORE " " TO MCR:AN
    STORE " " TO MCR:DESCR
    ? CHR(07)
  ENDIF
  LOOP
ENDDO
@ 11,0 SAY "            "
@ 11,0 SAY MCR:DESCR
@ 12,0 SAY " "
******************* ENTER NOTES *******************
DO CASE
  CASE MSELADD = "1"
    ACCEPT "Enter NOTES (1ST LINE) <CR>     " TO MNOTES1
    @ 14,0 SAY " "
    ACCEPT "Enter NOTES (2ND LINE) <CR>     " TO MNOTES2
  CASE MSELADD = "2"
    ACCEPT "Enter PAY TO THE ORDER OF <CR>     " TO MNOTES1
    @ 14,0 SAY " "
    ACCEPT "Enter CHECK NUMBER <CR>     " TO MNOTES2
  CASE MSELADD = "4"
    ACCEPT "Enter LOCATION or TRIP PURPOSE <CR>     " TO MNOTES1
    @ 14,0 SAY " "
    ACCEPT "Enter AUTO ID or MILEAGE <CR>     " TO MNOTES2
  CASE MSELADD = "6"
    ACCEPT "Enter ITEM PURCHASED or PURPOSE <CR>     " TO MNOTES1
    @ 14,0 SAY " "
    ACCEPT "Enter LOCATION/GUEST <CR>     " TO MNOTES2
  CASE MSELADD = "7"
    ACCEPT "Enter EXPENSE or PURPOSE <CR>     " TO MNOTES1
    @ 14,0 SAY " "
    ACCEPT "Enter LOCATION/GUEST <CR>     " TO MNOTES2
ENDCASE
***************************************************
@ 17,0 SAY " "
ACCEPT "Enter MORE TRANSACTIONS? (Y/N) <CR>" TO MANS
@ 19,0 SAY " "
IF MANS = "N" .OR. MANS = "n"
  STORE "N" TO MANS
ENDIF
DO ADDREC
RETURN
CANCEL