Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

When does COBOL send printout to the Windows spooler?

Status
Not open for further replies.

JerrMerr

Programmer
Jan 12, 2005
2
US
I am converting a mainframe COBOL program that:
a) defines one printer file with SELECT xxx ASSIGN TO
PRINTER yyyy
b) OPEN's it, WRITE's to it CLOSE's it
c) uses calls to the Exec to initiate printing of that file
d) uses an Exec call to reASSIGN the xxx printer to file
zzz.
e) repeats b thru d several times

So when does Fujitsu COBOL for Windows send the print file
to the Windows spooler? When the file is closed or when the program ends?
 
>So when does Fujitsu COBOL for Windows send the print file to the Windows spooler? When the file is closed or when the program ends?

I don't know about Fujitsu, but spoolers are collectors. They collect your data, and when you are done, when the print file is closed (even if the program has not ended), they send the data to the printer.


__________________________________________
Try forum1391 for lively discussions
 
It depends also on how the printer is configured, whether it is a network printer and other details.

For your program to do the same as is doing on the mainframe you need to convert the "print" file to a normal sequential file, and replace step "d" with a call system to copy from this sequential file to the printer. (or similar).

Regards

Frederico Fonseca
SysSoft Integrated Ltd
 
Dimandja is correct; when you close the file the spooler start sending to printer.
You do not need step c and d : only repeat step b.
You also do not need to close the program.
What release of fujitsu have you?
I have 7 but I always print using PowerForm : this is good because I am not concerned about what printer I am printing to.

Hope this will help you.

 
My printing is release when I close the printer. It will always print on your default printer and you have no choice of the font. Mine was printing so small I could not read it. Kind of depends on what type of printer you have. There is a way to control the Fonts and sizes. Fujitsu has a sample program that shows how to control Fonts and sizes. Look on their web site under sample programs for sample PRTFONT.ZIP.


etom
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top