PDF Writer

For questions and postings not covered by the other forums
stevek2
Posts: 14
Joined: Fri Nov 13, 2015 5:04 pm

PDF Writer

Postby stevek2 » Wed Dec 02, 2020 3:43 am

Hi all

Can someone recommend an easy to integrate (and robust) PDF writer (using ActiveX or .net)
We have been using a product called novaPDF writer and while easy enough it has constant issues and latest version does not integrate well with Jade

Regards
Stevek

User avatar
BeeJay
Posts: 312
Joined: Tue Jun 30, 2009 2:42 pm
Location: Christchurch, NZ

Re: PDF Writer

Postby BeeJay » Wed Dec 02, 2020 10:30 am

Hi Steve,

I've recently been testing using the Microsoft Print to PDF printer driver, which seems to be available on all recent Windows releases.

So far I've yet to hit any problems with sending JADE reports to this printer using app.printer.print( <frame> ) etc.

If you use app.printer.setPrintFileName( <filename> ) prior to starting your printing, then it also suppresses the 'file save' dialog.

Hope that helps.

Cheers,
BeeJay.

Any thoughts expressed are my own and in no way reflect the views of my employer. If this reply includes any sample code, I believe that this sample code is accurate and reliable and has been prepared with care but give no guarantee that the sample code will be free of defects or errors. No responsibility or liability, financial or otherwise, is accepted for any consequences arising out of the use of any sample code including loss of profits, indirect, special or consequential losses or damages.

Stokes
Posts: 66
Joined: Wed Oct 13, 2010 2:06 pm
Location: QLD, Australia

Re: PDF Writer

Postby Stokes » Wed Dec 02, 2020 10:51 am

Thanks for that BeeJay, if that works that would be amazing to get rid of our third party pdf software. Hopefully will get a chance to check this over the Christmas period when things are a bit quieter

mjagers
Posts: 17
Joined: Wed Sep 22, 2010 5:22 pm

Re: PDF Writer

Postby mjagers » Wed Dec 02, 2020 2:11 pm

We have moved to the Microsoft Print to PDF as well and have moved off a 3rd party PDF convertor.
To-date we've had no problems with the Microsoft Print to PDF driver.
regards
Martin Jagers

stevek2
Posts: 14
Joined: Fri Nov 13, 2015 5:04 pm

Re: PDF Writer

Postby stevek2 » Thu Dec 03, 2020 3:21 am

Thanks Beejay

I will start playing with this option straight away and hopefully this will solve my problems
I intended to use the print to file option as all our PDFs end up as attachments to emails anyway

Much appreciated
steve

stevek2
Posts: 14
Joined: Fri Nov 13, 2015 5:04 pm

Re: PDF Writer

Postby stevek2 » Thu Dec 03, 2020 4:54 am

Hi Beejay

Your solution worked a treat and is significantly easier over virtually every other third-party PDF writer

One question, I am trying to create the PDF output (via Jade printer output) but want to specify the default folder to be used
(without having to use the default Windows printer dialog)

When using app.printer.setFileName, Jade documentation indicates that the default folder is used (e.g. x:\Jade\bin) and only when the FILE: option is used do I get the dialog to change the folder location.

Is there another way that jade provides either
app.printer.setFolderName or (similar) OR
via the Jade ini file (e.g. section [JadePrinting])


Regards
Steve

User avatar
BeeJay
Posts: 312
Joined: Tue Jun 30, 2009 2:42 pm
Location: Christchurch, NZ

Re: PDF Writer

Postby BeeJay » Thu Dec 03, 2020 8:08 am

Hi Steve,

For my printing I provide a fully qualified filename such as the following sample code. For this code, I have the defaultFolder and the fileName in suitably named strings already. For this example, I'm assuming the defaultFolder string has a trailing '\' or '/' folder separator already appended to the string:

Code: Select all

app.printer.setPrintFileName( defaultFolder & fileName );

Cheers,
BeeJay.

Any thoughts expressed are my own and in no way reflect the views of my employer. If this reply includes any sample code, I believe that this sample code is accurate and reliable and has been prepared with care but give no guarantee that the sample code will be free of defects or errors. No responsibility or liability, financial or otherwise, is accepted for any consequences arising out of the use of any sample code including loss of profits, indirect, special or consequential losses or damages.

stevek2
Posts: 14
Joined: Fri Nov 13, 2015 5:04 pm

Re: PDF Writer

Postby stevek2 » Thu Dec 03, 2020 9:25 pm

Thanks Beejay

I had tried that option earlier but obviously missed something
Using fully qualified filename does the trick

Cheers
Steve

Stokes
Posts: 66
Joined: Wed Oct 13, 2010 2:06 pm
Location: QLD, Australia

Re: PDF Writer

Postby Stokes » Mon Jan 11, 2021 10:53 am

I just realised that this won't work for us because we generate HTML and turn that into the PDF. It will work for any standard Jade Print Form but most of our PDFs are HTML so clients can easily create/adjust them when required


Return to “General Discussion”

Who is online

Users browsing this forum: No registered users and 26 guests