home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 6 / 06.iso / a / a610 / 6.ddi / DEMO / FGL / R_LABEL.4GL < prev    next >
Encoding:
Text File  |  1989-12-08  |  845 b   |  29 lines

  1. DATABASE leads
  2. REPORT r_label(rr)
  3. {
  4. The r_label report prints mailing labels for prospects. 
  5. The output is sent to a file called label.out.
  6. }
  7.  
  8. DEFINE   rr                RECORD LIKE prospect.*
  9.  
  10. OUTPUT
  11.    REPORT TO "label.out"
  12.    LEFT MARGIN 0
  13.    TOP MARGIN 0
  14.    BOTTOM MARGIN 0
  15.    PAGE LENGTH 8  {change to the number of lines between the
  16.                    top of one label and the top of the next}
  17. FORMAT
  18. ON EVERY ROW
  19.    PRINT rr.title CLIPPED, 1 SPACE,
  20.          rr.fname CLIPPED, 1 SPACE,
  21.          rr.lname
  22.    IF rr.company IS NOT NULL THEN PRINT rr.company END IF
  23.    IF rr.add1 IS NOT NULL THEN PRINT rr.add1 END IF
  24.    IF rr.add2 IS NOT NULL THEN PRINT rr.add2 END IF
  25.    IF rr.add3 IS NOT NULL THEN PRINT rr.add3 END IF
  26.    PRINT rr.city CLIPPED, ", ", rr.state, 2 SPACES, rr.zip
  27.    SKIP TO TOP OF PAGE
  28. END REPORT
  29.