does anyone know how to pass the print control characters from Natrual to VTAM which intrun sends the streaming data onto printer where printer decides how many lines has to skip based on printer control characters.
your quick answer would appreciated!
If you use the standard Natural PRINT/WRITE/DISPLAY/EJECT/SKIP commands, they include the ordinary ASCII print control characters in the output stream in the print control column (first column). You may need to ensure that the DCB RECFM includes the “A” (RECFM=FBA or RECFM=VBA) to tell the operating system that your print control characters are included as the first byte of each line.
The advantage of the standard functions is that you can use the AT TOP OF PAGE, WRITE TITLE, etc event processing blocks to handle page functions.
If you are doing more complex processing, such as APF printer form control strings, another choice is to use WRITE WORK FILE statements, where you will need to keep track of when page headings are to be output or additional lines skipped.
I seem to recall an issue with sending reports through VTAM, and 3rd-party products resolving the problem, but I’ve never had to deal with this directly.
Regarding Doug’s post, you can control the carriage control character programmatically without replacing reports with WORK files. You must define the printers with the CCONTROL option.
DEFINE PRINTER (2) OUTPUT 'CCONTROL'