From: David E. <de...@us...> - 2006-12-29 09:06:26
|
Larry Jungers wrote: > Greetings to all. I tested OC and TC a couple of > years ago but gave up because some of the batch > programs where just to large to compile and > there was the issue of talking to a windows printer. > > Have remained on the list all this time and read > with interest what various people are trying to accomplish. > So maybe some changes have been made that might get > me back to testing once again. > > The programs where all written in M*cro F*cus Cobol > and several of the programs performed edits and file > updates. > Due to there size the programs where broken up into > SECTIONS. Is this now supported? Yes, SECTIONS have been supported for quite a while. However, they have not substantially tested, so I'm not sure if TC conforms to the COBOL standard. > The other issue I had was the printer side. > Would like to have a way to set the document name, port, > and copies. > In the old batch system a print spooler was used and > that allowed for report name, copies, hold Y/N and a > few other parameters before the Cobol program was run. > With windows the way it is today and a print spooler (the > two I know of) can not coexist together and function. > Has the print side been addressed or is there a work around? Even on the old batch system spooler (CICS also) the OS, or rather some sub-system, sends the file to the printer. All the COBOL program has to do is ASSIGN the file to some device defined by the system as a (vitual) printer. On Win32 (and UN*X), some other program, or the COBOL program itself, has to send the file to the print spooler. On UN*X it is easy as you can either emulate the 'batch system' with some script, or just add a CALL 'system' ... within the COBOL program. On Win32 it's more compilcated, as command line and GUI programs are handled differently by the OS. Either way you have to deal with the Win32 API. The Win32 work around ? Compile the COBOL programs as DLL's, and write some sort of GUI front end as batch substitute. Hint: To define a COBOL program as a Win32 GUI program, just add the '-mwindows' GCC command line option to the link step. > Would love to convert this to run on Linux but that's > another issue. In my experience, COBOL programs compiled with TC, will run faster on UN*X. Hope this helps. |