Sylvana
180 pts. | Oct 28 2009 7:34PM GMT
i have a printer file already, but i don’t know how to send to the printer everything i see in dspfile.
do you get it?
thanks .
Sylvana.
TomLiotta
7620 pts. | Oct 28 2009 8:28PM GMT
It will depend on how you defined your printer file. If you defined appropriate record formats, then you’d READ from the display file, MOVE field values from the display fields into the printer format fields, and WRITE the printer file format(s).
Assuming that you have correctly created your printer file, you SELECT it as:
SELECT ACH-REPORT-FILE ASSIGN TO FORMATFILE-ACHRPT.
You might have one format that describes all of the header lines on your report, another format that defines a detail line on your report, maybe another format that defines total lines.
Or you might define a single format in your printer file that defines all of the fields on the entire page. If your page is supposed to represent the fields on a display screen, then maybe a single printer file format is appropriate.
If your printer file has detail lines to list more than one detail item:
You WRITE once to print the header format. This format should define all lines that appear at the top of the page.
You then WRITE once for each detail line format that you want to print. Use the WRITE … END-OF-PAGE option if you want to use your printer file page-length to control execution of printing the next page header. This is probably done in a loop, once for each time you print a detail format.
When you’ve printed all detail lines in the group, WRITE any total format that you defined.
Before issuing a WRITE, MOVE any values into the format fields if you want the values to print.
Regardless, if we don’t know how you defined your printer file, we can’t say how to print it.
Tom
Sylvana
180 pts. | Nov 4 2009 4:13PM GMT
does exist a method to create a prtfile like sda for a display file?
please i need to create the reg.
thank you
sylvana






