Skip to Main Content

APEX

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How should I print a page to a PDF file?

Howard DunlavyDec 30 2015 — edited Jan 1 2016

This is definitely a "newbie" question. I have been asked to look into how to print a web page created in Apex to a PDF file.

I inherited this application from someone else, and have had no experience in Apex before this, so my question may be one that has no simple answer. I have looked through the Apex documentation extensively looking for an answer, but have hit a dead end.

This is an existing page that is setup as follows:

  1. The page is composed of 3 Regions.
  2. The first Region is of type "Static Content". This Region has a list of individual fields in the Items area. It also has a SubRegion which is of type "Classic Report".
  3. The second Region is of type "Classic Report". It consists of a small set of fields of which there will be 1 or more rows.
  4. The third Region is of type "Classic Report". It also consists of a small set of fields which have will 1 or more rows.

I am able to set the attribute for the Regions of type "Classic Report" to Printing Enabled, and I then get a "Print" link in each Region, which does work to create a PDF file showing just that Region. So I know the PDF printing functionality is setup correctly.

What I want to be able to do is print all of the Regions in one PDF file.

The programmer who setup this form created a Print button, with an action of "Redirect to URL", with the target being "Page 0". When I click on this button, I received the following error: "Error occurred while painting error page: ORA-01403: no data found ORA-20001: The printing engine could not be reached because either the URL specified is incorrect or a proxy URL needs to be specified."

So it seems like if I had the correct URL (rather than "Page 0"), this might work. I have been looking through the Apex documentation for a while trying to find a reference to what this URL would be, but have not been been able to find anything.

We are using Apex 5, Oracle 12. This behavior happens in either IE11 or the current version of Chrome.

So any suggestions on where to look for information would be great!

Thanks.

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jan 29 2016
Added on Dec 30 2015
6 comments
2,196 views