home *** CD-ROM | disk | FTP | other *** search
/ Shareware Overload / ShartewareOverload.cdr / database / formdb2.zip / MAIL.CMD next >
OS/2 REXX Batch file  |  1987-02-14  |  2KB  |  56 lines

  1. NOTE Example dBASE Command file program
  2. *
  3. *  - this is a sample form letter generator and mailing label 
  4. *  - dBASE II system.  The system allows the user to add new 
  5. *  - entries to a mailing list, print the mailing list on gummed
  6. *  - labels or print a form letter addressed to all the people 
  7. *  - in the mailing list.  No provision is made to modify the 
  8. *  - mailing list.  The user can use the dBASE commands EDIT and/or
  9. *  - DELETE to modify the database file MAIL.DBF to change the 
  10. *  - mailing list.
  11. *
  12. *  - turn off display of commands to screen
  13. SET TALK OFF
  14. *  - assign database file to command stream.
  15. USE MAIL
  16. *  - enter current date to print on form letter
  17. ACCEPT 'Enter date as mm/dd/yy' TO DATE
  18. *  - select system option
  19. DO WHILE T
  20.    ?
  21.    ?
  22.    ?
  23.    ? '          Form Letter Writing System'
  24.    ?
  25.    ?
  26.    ? '          0 - EXIT'
  27.    ? '          1 - Enter new entries'
  28.    ? '          2 - Make Labels'
  29.    ? '          3 - Write Letters'
  30.    ?
  31.    ? ' enter desired action'
  32.    *  - wait for user response
  33.    WAIT TO ACTION
  34.    *  - test for exit 
  35.    IF ACTION='0'
  36.       SET TALK on
  37.       CANCEL
  38.    ENDIF
  39.    *  - test for new entries
  40.    IF ACTION='1' 
  41.       *  - add new names to MAIL.DBF
  42.       DO MAILENTR
  43.    ENDIF
  44.    *  - test to make labels
  45.    IF ACTION='2'
  46.       *  - print mail labels
  47.       DO MAILLAB
  48.    ENDIF
  49.    *   - test to write form letters
  50.    IF ACTION='3'
  51.       *  - print form letter to names in MAIL.DBF
  52.       DO MAILLTTR
  53.    ENDIF
  54. ENDDO
  55. RETURN
  56.