Environment
EXTRA! X-treme 9.5
Situation
How to have each 3270 printer emulation output file take on a sequentially numbered name when sending multiple jobs to FILE.
Resolution
Complete the following steps to use wildcard operands in a file name to print sequential files that are unique for each print job:
6. Click the OK button to save the settings.
When the job prints, the question marks are replaced with sequential numbers that automatically increment for each additional print job. If the value in the "File Name" box is C:\TEMP\???.TXT, a file named 000.TXT is placed in the C:\TEMP directory for the first print job. For the next print job, the file 001.TXT is created and each additional job increments the counter to the next value.
When the counter is incremented, the EXTRA! printer session looks for the presence of an existing file with that same value. If found, it continues incrementing the number of the file until the first non-existent filename is encountered. If the previous file printed was named 001.TXT, and the files 002.TXT and 003.TXT already exist, then the next file is 004.TXT. Once the counter increments to the maximum boundary (999 in this case), it then starts over at 0 (000). To manually reset the counter back to 0, exit and restart the printer session.
The number of files which can be created depends on how many question marks are used. If the wildcard file is specified as ?.TXT, then only 10 files can be created (0-9) and be present at the same time. If ??.TXT is specified, then 100 files can be created (00-99), and so forth.
1. From the EXTRA! Printer session, select Options followed by Settings.
2. From the Categories list, highlight Printer.
3. On the Printer tab, click on the "File" radio button as the Destination.
4. In the File Name field, enter the path and a file name that contains one or more question marks ("?").
5. To prevent printer control codes from being saved with the file, click on the option to Bypass Windows GDI Printing System.
When the job prints, the question marks are replaced with sequential numbers that automatically increment for each additional print job. If the value in the "File Name" box is C:\TEMP\???.TXT, a file named 000.TXT is placed in the C:\TEMP directory for the first print job. For the next print job, the file 001.TXT is created and each additional job increments the counter to the next value.
When the counter is incremented, the EXTRA! printer session looks for the presence of an existing file with that same value. If found, it continues incrementing the number of the file until the first non-existent filename is encountered. If the previous file printed was named 001.TXT, and the files 002.TXT and 003.TXT already exist, then the next file is 004.TXT. Once the counter increments to the maximum boundary (999 in this case), it then starts over at 0 (000). To manually reset the counter back to 0, exit and restart the printer session.
The number of files which can be created depends on how many question marks are used. If the wildcard file is specified as ?.TXT, then only 10 files can be created (0-9) and be present at the same time. If ??.TXT is specified, then 100 files can be created (00-99), and so forth.