APPLICATION NOTE #149 PRINTING MAILING LABELS Rev. 04 There are several ways to approach label printing, depending on the type of printer you are using, the structure of your data file, and the format of your labels. This application note describes two procedures: one for printing single-width labels on a dot matrix or daisy-wheel printer, and another for printing multiple-width labels on any type of printer. Both procedures assume you have a Mail Merge data file that contains the names and addresses you want to print on the labels. PRINTING SINGLE-WIDTH LABELS To print single-width labels on a dot matrix or daisy-wheel printer, you don't need to alter the data file at all. Just create a new main file that contains the following formatting commands for the labels. * FI (Field Identification) command. * Form Depth. Measure from the top of one label to the top of the next. Multiply the result by 6 (6 lines per inch). * Page Length. Set the page length to one less than the form depth. * Left and Right Margins. Measure the width of the label in tenths of an inch. * Top Margin. * Form Feed. Set FF to 0 to prevent XyWrite from sending a form feed to the printer at the end of every page. * PF (Put Field) commands. For a label that is 3 inches long and 4 inches wide, the main file might look like this in expanded mode. <><><><><><< tp5>><> <> <> <>, <> <> Be sure there are no extra carriage returns in the main file. Now just use the TYPE + command to merge the data file with this new main file and output the results to the printer. PRINTING MULTIPLE-WIDTH LABELS To print multiple-width labels, you must make some changes to your data file. Therefore, we recommend that you first make a copy of that file. Save the original version for use with XyWrite's Mail Merge feature, and modify the copy for printing multiple-width labels. Call the copy of the data file to the screen and check the format of the records. Because we are not going to use the Mail Merge feature to print the multiple-width labels, you may have to make some modifications. For example, if you used an asterisk as a field separator, change it to carriage return. Type: F5ci /*/Cntrl-/ If there are fields that you do not want to print, delete them. Let's say you have a file called DATA that contains the names and addresses you want printed, but it also contains a salutation field in each record. A typical record might look like this: Joseph Brown Main Street Townsville, PA 10011 Dear Joe, To eliminate the salutation field: 1. Display the Memory Usage menu and unload the printer file. Press: Ctrl-M Press: {Cursor Down} (once) Press: 7 2. Create a new main file. For example: Type: F5ne label 3. Set the form feed to zero. Type: F5ff 0 4. Enter the Put Field commands for the fields you want to print on your labels. 5. Type an extra carriage return after the last Put Field command. Result: In expanded display, the LABEL file might look like this: <><> <> <> 6. Use the TYPEF + command to create a file that contains only the fields you want to print. Type: F5typef data+label,data.rev Result: The new file, DATA.REV, contains the name and address from each record in DATA, but it does not include the salutation. Next, insert a PG (Page Break) command between each record in the revised data file. You need this command to accommodate addresses of different lengths. Move the cursor to the top of the file, switch to expanded display, and issue the following command: Type: F5ci /Cntrl-Cntrl-/Cntrl-<>Cntrl-/ Once that is done, enter the appropriate FD, PL, TP, RM, and LM commands at the top of the file (refer to the procedure for printing single-width labels if you need help determining these values). Enter an FF 0 command to prevent a printer form-feed, and then enter a snaking command to create newspaper-style columns. For example, if you are printing on 2.5-inch-wide labels, and there are three labels across the page, the snaking command might be SN 0,25,50. If you are using a dot matrix or daisy-wheel printer, that's all you need to do to the address file. If you are using a laser printer, there is one more step. Because you set FF (Form Feed) to zero, you must manually send a form feed to the printer between each physical page. You use a PI (Printer Insert) command to do this. If you are using a Hewlett-Packard LaserJet printer or equivalent, use the PI command to insert an ASCII 12 character. You need to put the PI command at the beginning of the first line of text on every physical page (except page 1): Type: F5pi {ASC-12} In expanded mode, the line would look something like this: <>Mr. Jim Jones However, if your address file contains a TP command, the format is different. HP printers process PI commands in a way that disables TP commands, which means that you must place the vertical spacing inside the PI command. The form of the vertical spacing statement is: {esc}*pnY where n is the value of the top margin; determine this value by multiplying the number in the TP command by 50. For example, if you are using TP3, the PI command would read: F5pi {ASC-12}{esc}*p150Y Note: HP LaserJet Classic. If you are using the HP LaserJet "Classic," the form of the vertical spacing statement is: {esc}&a+nV where n is the value of the top margin; determine this value by multiplying the number in the TP command by 120. Let's use the same example of an address file that contains a TP 3 command. If you add this vertical spacing statement to the form feed command described above, the PI command would be: F5pi {ASC-12}{esc}&a+360V If you are using an Apple LaserWriter or other PostScript printer, insert the following PI command at the bottom of every physical page (before the PG command). F5pi )s save showpage restore /x 18 def /y 780 def l( For most other laser printers, the PI command should read: F5pi {ASC-12} Now you're all set to print your labels. Make sure your printer is ready and then issue the TYPE command. Tip: Many stationery suppliers offer multiple-width labels suitable for use in photocopy machines. That means that you can print your addresses on regular printer paper and then photocopy them onto labels. This is useful if your laser printer does not handle labels well, or if you do frequent mailings to the same group of people. You only have to print the addresses once; you can store the masters and copy as often as needed.