z/OS Infoprint Server User's Guide
|
Previous topic |
Next topic |
Contents |
Index |
Contact z/OS |
Library |
PDF
Examples -- lp z/OS Infoprint Server User's Guide SA38-0695-00 |
|
Examples -- lpPrint a file on the default printerTo submit the file File1 to your default printer, enter:
Print a file on a specified printerTo submit the file File1 to the printer fred, enter:
Print a file on an undefined LAN printerYou want to print the file File1 on a LAN printer at a remote site. Your administrator has not defined this printer. You must specify:
Enter:
Print an MVS data setTo submit the MVS™ data set hlq.FILE1.LISTPS to your default printer, where hlq is your user ID, enter:
To submit the MVS data set FILE2.LISTPS to your default printer, enter:
Print a multi-document jobTo submit the files File1 and File2 to the default printer, enter:
Each file is spooled to the printer separately. Print a file-reference documentA file-reference document is a list of similar printable files that are separated by spaces, tabs, or new lines. For example, the file bills.list contains a list of files, each containing one customer’s monthly statement. It looks like this:
To print all the files listed in bills.list on your default printer, enter:
The files are concatenated and printed as a single file. Transform and print a jobIf a transform product is installed, you can submit a job in a format different from the ones the printer accepts. To print the PCL file sample.pcl on the AFP printer printer1, enter:
If you want to specify options for a file that is being transformed to AFP, you must use the filter-options attribute with the lp command. For example, to print pages 3–10 of the PCL file sample.pcl on the AFP printer printer1 as an overlay, enter:
If you want to specify job attributes for a file that is being transformed from AFP, you do not use the filter-options attribute with the lp command. You only use filter-options to specify -c and -i options. For example, to print the AFP file sample.afp on the PCL printer PCLPRT and printing in duplex, enter: To print the AFP file sample.afp on the PCL printer PCLPRT using the transform class US and print in duplex, enter:
Print multiple copies of each fileTo print two copies of each file on the default printer, enter one of these: This command prints two copies of Title, followed by two of Contents, and so forth for each file in the job. Tip:
VTAM-controlled printers (IP PrintWay™ basic mode only) and
some IPP-enabled printers do not support printing more than one copy.
In this case, only one copy prints. If the file is sent to an email
destination instead of to a printer, only one copy is sent. Print a file on both sides of the paperTo print file File1 on the default printer and to print it on both sides of the paper, enter:
Specify the attributes filesTo print file File5 on the default printer and to specify the two attributes files default.att and special.att, enter:
Suppose that the file default.att contains these lines: The file special.att contains these lines: The preceding command is equivalent to this command:
The value of input-tray in special.att overrides the value in default.att because you specified special.att last. Tip:
These examples assume that the attributes
files are in the current directory, or that you have set the AOPPATH environment variable to include the directories
where the attributes files reside. If this is not the case, you would
specify the attributes files by their absolute path names. Override an attribute value in an attributes fileTo print file File1 on the default printer and override the value of yes for the duplex attribute specified in the default.att attributes file, enter:
Specify the AOPOPTIONS environment variableTo set the AOPOPTIONS environment variable to your address, add a line like this one to your .profile file:
Until you reset the AOPOPTIONS environment variable, every lp command you enter includes this value. For example, this command: is equivalent to:
Because the lp command reads the value of the AOPOPTIONS environment variable before the options you specify on the command line, you can override the values of this variable. For example, if you want a single job delivered to a different address, enter:
Request notification by messageTo print file File1 on the default printer and to receive a message when the file is printed, enter:
Tip:
If the printer is a LAN printer,
the lp command writes an email when the file
is transmitted to the printer. When you receive the email, the file
might not actually have finished printing. Submit and hold a jobTo submit file File1 to the default printer and to hold it so that it does not print until the operator releases it, enter:
Specify a code page for ASCII filesTo print the files File1 and File2 and to specify the code page ISO8859-1, enter:
Print from standard inputYou can use the lp command to print the output from other commands. For example, to print a list of all the files in the current directory, enter:
Paginate line data and print with a header on each pageIf your administrator has specified the LPD compatibility filter (lpd_compat.so) for the printer in the Printer Inventory, you can specify filter options that are equivalent to the FILTER, WIDTH, and LINECOUNT options of the z/OS Communications Server (TCP/IP) LPR command. The LPD compatibility filter can be used with text and line data when you print on an AFP printer or a JES line printer. For a description of the options that the LPD compatibility filter supports, see filter-options. To print data set MYDATA, which contains line data, on the AFP printer afpprinter, with a header on each page, a maximum width of 80 characters, and a maximum length of 60 lines, enter:
Send multiple files to an email destination specified in the printer definitionTo send files File1 and File2 to the email address list in printer definition deptmail, specify a subject for the email, and specify a form definition that is used when the AFP data is converted to PDF format, enter: This example assumes that the AFP to PDF transform is requested for AFP data in the printer definition named deptmail. Results: The recipients listed in printer definition deptmail receive two emails:
Send a file to an email destination specified in job attributesTo send file File1 to the email addresses specified in job attributes instead of to the email addresses specified in the printer definition, and also specify a subject, sender name, attachment name, and reply address for the email, enter this command on one line:
This example assumes that the AFP to PDF transform is requested for AFP data in the printer definition named emaildest. Results: An email is sent with these specifications:
|
Copyright IBM Corporation 1990, 2014 |