tmannais
10th January 2019, 10:44
I have a device SSRS (SQL Server Reporting Services) that will print out the SSRS report. The device is setup correctly and is working fine in the system. It can be downloaded into several file types such as word, excel, and pdf manually.
Now I want to use AFS to get the SSRS report in the PDF format.
How can I do that?
I tried using

stpapi.set.report(session.code, report.code, "SSRS", error.msg)

to print the report in SSRS device, but cannot save it into PDF.

JaapJD
10th January 2019, 11:25
You can create a device in LN that stores a PDF in a location on the LN server. See the "Infor Enterprise Server Plug-in for Microsoft SQL Server Reporting
Services Administration Guide" for that (the -path argument). Use that device in instead of "SSRS". If you want to display the PDF directly to the user, you can try to set spool.fileout to a temporary file as described in the AFS guide and use '-path $file' in your device definition. Then you know exactly the file that will be created and that file can be displayed with client.show.file().

tmannais
11th January 2019, 03:30
It works as expected now.
Thank you very much, JaapJD.
Case Closed.