gentercz
20th July 2004, 15:25
Hi all,

we are currently setting up a DMS system. Which will get a BaaN interface.
Meaning all BaaN reports should be printed on paper and/or archived into DMS.

I was thinking about this solution:
1.) Create a new device with an own "conversion program"
2.) In this conversion program, i let the user choose the printer for paper work and another choice field for "send to DMS: yes/no".

So far so good.

The problem to send the report to DMS is solved (first i convert it to postscript (with "ottstpconv" then archive it as .pdf).

My problem is to send the report to a printer (Windows or Unix).
Because i am not able to program/influence "ottstpconv" that it uses either Unix Print Spools plus Driver or Windows Printing Devices.

I hope i made myself clear. Is there anybody who can help me ?

Regards,
Jochen

mark_h
20th July 2004, 16:07
This might work - for each printer(printers named like PRT1DMS) create a new ottstpconv. You also have a normal device named PRT1 - with proper setup for printing hard copy. The first thing it does is convert to postpost script to take care of the DMS requirement. Next convert the tmp file to ascii. At this point create as many new reports as needed - 1 for potrait and one for landscape. These reports would have one string input field and only a detail layout. Set your spool.device to the actual printer - PRT1. Then seq.open the ASCII file read each line and send it to the printer device using the report send option. You can find the layout of the printers by search the device table for PRT1 - then you know whether to open a portrait or landscape report. Not actually done this and you may have to use the brp.* commands - and it may not even work. This qualifies as my thought for the day.

I use something like this for batch reports. The batch runs and creates ascii files. The user then runs my Baan session to select which reports and which sections to print. The session then opens a dummy report with only one detail layout of string 132 and I do a send to this report of the string. This way the user can print only the sections they want of these 4 different reports. The difference between above and here is that I use a session and not a ttstpconv type routine.

Mark