Question
Public Safety Canada
CA
Last activity: 4 Oct 2018 13:54 EDT
How to 'View as PDF'?
Hi,
I need to implement an action on my case similar to the "View as PDF" as seen on discussion threads here:
But I don't know where to start to configure this. What is behind this button/link? What do I need to create? A harness? New CSS stylesheet? How do I format the sections the way I need them to display? I would like, as much as possible to just reuse the same sections as laid out on the screen, but sometimes need to adjust for page width.
I could really use a general introduction to generating PDF. I found some activities that might apply, but have no idea which to use/when, or what to put in the required parameters.
I am in version 7.1.8.
Thanks in advance.
**Moderation Team has archived post**
This post has been archived for educational purposes. Contents and links will no longer be updated. If you have the same/similar question, please write a new post.
-
Like (0)
-
Share this page Facebook Twitter LinkedIn Email Copying... Copied!
Pegasystems Inc.
IN
Hi Marie,
See the following video it might help: https://community.pega.com/pegatube/support-guide-troubleshooting-cyrillic-script-not-appearing-generated-pdf
HTMLtoPDF is the activity which will be needed to generate the pdf, Pega uses the third party tool pd4ml to generate the following pdf file. If you can share more on what section you are planning to show as pdf I will try to help.
Thanks
Public Safety Canada
CA
Thank you for the video. But I really need to start even more at the beginning - where do I call this activity from? Directly from the actions on my Link control? Sorry, I really am a newbie on this topic!
I essentially need to print an entire work item, including the complete request details we received and the history of all actions taken. We have everything laid out in dynamic layouts (including many fairly wide grids), which would need to be adjusted for a fixed page width.
Pegasystems Inc.
IN
Hi
You can refer the activities PrintWork which loads the printharness of a workitem.
Then you can refer the activity pyViewAsPDF to understand how you can use the markups to pass it to HTMLtoPDF activity and get the PDF generated.
Public Safety Canada
CA
Hi Santanu,
Thank you for you reply. I tried to use activity pyViewAsPDF, but I do not understand what is needed in the parameter "HTMLstream", nor what is meant by "markup" as a parameter to HTMLtoPDF.
I really do need to start at the VERY beginning! (Sorry:-S) As in, I have a link in a section called "Print to PDF" - what do I put in the click Actions of this link?. And once I get something to generate, then I'll need to adjust the formatting so it fits neatly on a page.
Any guidance you can provide is greatly appreciated!
Pegasystems Inc.
IN
Give me sometime. Let me see if I can put together some screenshot for you !
Pegasystems Inc.
IN
Hi Marie,
You can try the following scenario.
1. Create one Harness and it that harness add following section which you are planning to print as part of your pdf file.
2. Create an Activity in which call PrintWork and pass that Harness Name and run.
This will not make a pdf file, but you can directly print the following harness data from there.
Ex. Directly run the PrintWork activity --> Harness Name: "Perform " click Print will enable the printer for you to print the data.
Thanks
Gaurav
Bank Of America
US
Hi Gaurav,
If I want to print directly to my default printer what are the next steps.User don't want to print using Print Button.
Thanks,
Ashish Kumar
Commonwealth Bank of Australia
AU
Hi,
Above mentioned works well with browser Chrome but not with IE. Could anyone please provide a solution to make it work in IE.
Thanks
Pegasystems Inc.
IN
Hi,
Thank you for posting your query in the PSC. This looks like an inactive post and hence, we suggest you create a new post for your query. Click on the Write a Post button that’s available on the top right pane of this page. Once created, please reply back here with the URL of the new post.
You may also refer this discussion link as a reference in the new thread.