Focal Point
[CLOSED] Sending Webfocus Report to Printer

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/5567004236

July 24, 2013, 09:47 AM
santu
[CLOSED] Sending Webfocus Report to Printer
Hi All,

Is it possible to send a PDF report directly to a online printer.

I searched in the forums, there are no related posts about sending PDF reports to the printer.

I am currently using WF 7.7.03.

Is Report Caster the only option to do this? If not can we call a Report Caster schedule from a Webfocus fex or even JAVA application.

Any help will be appreciated.

Thanks in advance.
Santu

This message has been edited. Last edited by: <Kathryn Henning>,


Web FOCUS 7.7.03
PDF
July 25, 2013, 05:09 PM
Rakesh P
Hi Santosh,

As per my understanding, you have to use the report caster APIs to call the printer from JSP. The report caster API documentattion
is available in the tech support site.

The Print agent name is : DSTSchedFactory.METHOD_PRINT. You need to pass the Printer IP to this method somehow.

Also note that the o/p format for the Printer fex should be 'PS'. means, you need to hold the data in PS format.


Webfocus 7.1.6, Webfocus 7.7, Webfocus 8
July 25, 2013, 06:58 PM
prodrigu
Santu,

The printer needs to be set up on each box (DEV,ACC,PRD). Example, our development box is (modapp150d) and you need to add the printer to this. Then create a procedure which will save your pdf report to a specific location path. Once its save then use -WINNT command to call a .bat file which you will use PRINT command to send your report a specific printer.
Batch file would look like this:
 
@ECHO OFF
@ECHO. 
PRINT /D:%1 "%2"
EXIT /b 0


The -WINNT would look something like this (
-WINNT D:\ibi77\wmgtmp\WMBatchPrint.bat &PRINTER &PATH 
).

Your &PRINTER would like this (\\modprt011\GTC113LJ01)(\\server_name\printer_name) and your &PATH would look like this (
 D:\ibi77\wmgtmp\IBI_wmg0001-batch_printing\report_pdf.ps 
).

In our case we had to sent the job over as postscript.

I summed this up but if you need additional information please let me know. This should get your started.

Thanks,
prodrigu


Prod: WebFOCUS 7.7.03: Win 2008 & AIX hub/Servlet Mode; sub: AS/400 JDE; mostly Self Serve; DBs: Oracle, JDE, SQLServer; various output formats
August 06, 2013, 07:14 AM
Ian Dalton
You try this as it works for us:-
FILEDEF NSCAPR04 DISK C:\TEMP\NSCAPR04.PDF
-RUN
TABLE FILE CAR
PRINT CAR BY COUNTRY
ON TABLE HOLD AS NSCAPR04 FORMAT PDF
END
-RUN
-------------------------------------
-* WebFOCUS printing (.PDF file only)
-*-----------------------------------
COPY C:\TEMP\NSCAPR04.PDF &&PRNTR..
-RUN

where &&PRNTR is a 'share' set up on the printer you need to print on


_______________________
*** WebFOCUS 8.1.05M ***
September 23, 2013, 12:03 PM
prodrigu
Ian,

Do you have logging set up to capture if the report fails or is successful when printing to a printer? I am using this technique but time to time the report fails to print to a specify printer and I don't know if its WebFOCUS messing up or its the network.

Please let me know.

Thanks,
prodrigu


Prod: WebFOCUS 7.7.03: Win 2008 & AIX hub/Servlet Mode; sub: AS/400 JDE; mostly Self Serve; DBs: Oracle, JDE, SQLServer; various output formats
September 27, 2013, 09:36 AM
Ian Dalton
No we don't have logging but I am sure you can turn it on to see whether it's a network issue or not. Speak with your printer people.
Suggest you use SET EMPTYREPORT=ON so that if there is no data cominh from WebFOCUS, at least a blank report (ie. headings only) will be printed.


_______________________
*** WebFOCUS 8.1.05M ***