

Data Manipulation Language Statements › #PRINT—requests that the system transmit data
#PRINT—requests that the system transmit data
The #PRINT statement requests that the system transmit data from a task to a terminal defined as a printer device during system generation. The terminal designated as a printer is usually a hard-copy device. The following considerations apply to the use of the #PRINT statement:
- The DC/UCF system does not usually transmit data directly from program storage to the terminal in response to a #PRINT command. Data is passed to a queue maintained by the system, then from the queue to the printer terminal. The data stream passed to the queue by the #PRINT request contains pure data; the system inserts line and device control characters automatically when it writes the data to the printer.
- To bypass the queuing process described above and to transfer data immediately to a printer device, issue a print-direct request by specifying #PRINT OPTNS=(DIRECT).
- You can use a #PRINT request to transmit native-mode data streams, data streams that contain device-control information as well as user data. This capability is useful in formatting reports for 3280-type printers. To transmit native-mode data streams, you issue a #MREQ NOIO request, followed by a #PRINT request with OPTNS=(NATIVE).
- Each line of data transmitted by a #PRINT request is considered a record. Each record is associated with a report in the print queue. A report consists of one or more records. Each task can have up to 256 active print reports. A program can issue multiple #PRINT requests, each specifying a different report. The DC/UCF system maintains the status of each report individually.
- The #PRINT request transmits data or screen contents to print classes or to destinations:
- Print classes—During system generation, one or more print classes are associated with each terminal designated as a printer. For each report, the first record transmitted to the print queue with a #PRINT request establishes the print class in the range of 1 to 64 for that report. The report is printed on the first available printer assigned the same print class.
- Destinations—Destinations are groups of terminals, printers, or users. If destinations have been defined during system generation, the #PRINT request can direct a report to a destination. Reports sent to printer destinations are printed either on the first available printer for the destination or on all printers in that destination, regardless of print class.
- You can request that the system hold the report rather than print it immediately. You can explicitly release the report at a later time.
- The DC/UCF system prints a report only when that report is completed, either explicitly as part of a #PRINT request or implicitly when the issuing task terminates. If the task abends, all reports in the print queue that have not been ended explicitly are deleted without being printed.
- After completion of a #PRINT request, register 1 contains the address of a 10-character identifier that uniquely identifies the report in the DC/UCF system. This identifier is not the user-defined report ID described below for the RPTID parameter. It is a value assigned by the system primarily for internal use. This value appears on the master terminal when report statistics are requested from that terminal.
- A report can be printed several times by indicating to the system to keep the report after it has been printed, rather than automatically deleting it. The report can be manually released to be printed using a DCMT VARY REPORT RELEASE command.
Copyright © 2014 CA.
All rights reserved.
 
|
|