Forum

Overaly example dt109941.app and print PDF direct to Printer

This Forum is for the use of Clarion For Windows - Software Developers requiring help and assistance for Tracker Software's PDF-Tools SDK of Library DLL functions(only) - Please use the PDF-XChange Drivers API SDK Forum for assistance with all PDF Print Driver related topics.

Moderators: Tracker Support, Lesya - Tracker, Vasyl-Tracker Dev Team, Chris - Tracker Supp, Tracker Supp-Stefan, Tracker - Clarion Support, John - Tracker Supp, Ivan - Tracker Software, Support Staff, moderators

Overaly example dt109941.app and print PDF direct to Printer

Postby hector g pabon on Tue Feb 21, 2012 4:38 pm

Hi,

Windows XP SP3, C 6.3 9058, no 3rdP Previewer.

In example dt109941.app text data is first previewed without the merge PDF form.
Then, the final user select to print the report and the merge text with the overlay form
is presented or printed.

If the text data is not previewed, there is no merging of data with the overlay.

I like to print the text data with the overlay to a specific printer without previewing it and without user intervention.

The idea is to place the text data in a folder and have a program watching on that folder. Then, when there is a data file is detected perform the merge and print the overlay to a printer already
defined in the application.

Any help will be appreciated.
hector g pabon
User
 
Posts: 13
Joined: Fri Feb 17, 2012 3:33 am

Re: Overaly example dt109941.app and print PDF direct to Pri

Postby Tracker - Clarion Support on Tue Feb 21, 2012 6:23 pm

Hi Hector!

This is using PDF-Tools, correct?

If so, all you have to do is go to the PDF-Tools template Previewer tab and set Run Print Previewer (near the bottom of the tab) to No. Try it with dt109941.app.
Craig Ransom
Tracker Software - Clarion Support
http://www.tracker-software.com
Tracker - Clarion Support
Site Admin
 
Posts: 1351
Joined: Wed Jun 30, 2004 4:45 pm
Location: Maryland, USA

Re: Overaly example dt109941.app and print PDF direct to Pri

Postby hector g pabon on Tue Feb 21, 2012 9:24 pm

Hi Craig,

Corect, I'm using PDF -Tools.

With your suggestion I manage to bypass the previewer and using PRINTER{PROPRINT:Device}=
'HP LaserJet' I was able to print directly to the specified printer.

But, it only prints the text data without the overlay. The generated(created) PDF was
created with the overlay.

Maybe I have to create another program who takes the generated PDF and send it to the
specific printer. I'm only half way to what I'm trying to accomplish.

Appreciate any help.

Hector
hector g pabon
User
 
Posts: 13
Joined: Fri Feb 17, 2012 3:33 am

Re: Overaly example dt109941.app and print PDF direct to Pri

Postby Tracker - Clarion Support on Wed Feb 22, 2012 1:02 am

Hi Hector!

What are you using to do the PDF-to-Print?
Craig Ransom
Tracker Software - Clarion Support
http://www.tracker-software.com
Tracker - Clarion Support
Site Admin
 
Posts: 1351
Joined: Wed Jun 30, 2004 4:45 pm
Location: Maryland, USA

Re: Overaly example dt109941.app and print PDF direct to Pri

Postby hector g pabon on Wed Feb 22, 2012 2:38 am

Craig,

Just plain Clarion, no 3rd Party.

Hector
hector g pabon
User
 
Posts: 13
Joined: Fri Feb 17, 2012 3:33 am

Re: Overaly example dt109941.app and print PDF direct to Pri

Postby Tracker - Clarion Support on Wed Feb 22, 2012 1:39 pm

Hi hector!

I meant what are you using to print the PDF file to paper? Is it our Viewer or Adobe? Or something else?
Craig Ransom
Tracker Software - Clarion Support
http://www.tracker-software.com
Tracker - Clarion Support
Site Admin
 
Posts: 1351
Joined: Wed Jun 30, 2004 4:45 pm
Location: Maryland, USA

Re: Overaly example dt109941.app and print PDF direct to Pri

Postby hector g pabon on Wed Feb 22, 2012 4:59 pm

Hi Craig,

The problem is that I need to print the PDF direct to the printer without opening any viewer.

Or there is a way to tell the Tracker Viewer to open the overlay and automatically send it to
an specified printer?

I look at the generated PDF overlay saved on Disk and it looks ok.

Hector
hector g pabon
User
 
Posts: 13
Joined: Fri Feb 17, 2012 3:33 am

Re: Overaly example dt109941.app and print PDF direct to Pri

Postby Tracker - Clarion Support on Wed Feb 22, 2012 5:48 pm

Hi Hector!


We don't have a PDF-to-print as such. You could try using ShellExecuteEx with the "printto" action specified which will try to open and print the PDF using whatever program handles your PDF viewing.

Our Viewer ActiveX can handle that however, but you have to embed that in your program.
Craig Ransom
Tracker Software - Clarion Support
http://www.tracker-software.com
Tracker - Clarion Support
Site Admin
 
Posts: 1351
Joined: Wed Jun 30, 2004 4:45 pm
Location: Maryland, USA

Re: Overaly example dt109941.app and print PDF direct to Pri

Postby hector g pabon on Thu Feb 23, 2012 3:27 am

Craig,

I think that the PDF Viewer "Silent PDF to Print Sample" can do the job with some tweaking.

Basically assigning the specified printer, watching a folder for file name capturing and
clicking the "Print" button with a hot key.
hector g pabon
User
 
Posts: 13
Joined: Fri Feb 17, 2012 3:33 am

Re: Overaly example dt109941.app and print PDF direct to Pri

Postby Tracker - Clarion Support on Thu Feb 23, 2012 12:25 pm

Hi Hector!

Yes the ActiveX Viewer can do that nicely. One thing to remember - therre is a checkbox on the Viewer ActiveX Procedure Template that allows you to Hide the OLE control that it's running in. And, if you do that, you can reduce the size of the OLE control to very small.

One thing to be aware of though! There is a bug in the current Clarion 8 Runtime Library that can cause an access violation if you try to print too many PDF files one after the other. We have PTSS #39063 open on the problem in SV's PTSS.

Please see http://www.tracker-software.com/forum3/viewtopic.php?f=38&t=12469 for more info.
Craig Ransom
Tracker Software - Clarion Support
http://www.tracker-software.com
Tracker - Clarion Support
Site Admin
 
Posts: 1351
Joined: Wed Jun 30, 2004 4:45 pm
Location: Maryland, USA

Re: Overaly example dt109941.app and print PDF direct to Pri

Postby hector g pabon on Sat Feb 25, 2012 4:52 am

Craig,

Everything works perfect once I tweak the application but only in my server. PDF Overlay is printing
with no user intervention and no preview.

At the client server, there is another story. My program doesn't open any window although I can
see it running in the task manager. When the customer try to print an overlay test, the program generates the PDF perfectly (with the overlay) but there is no printing.

Maybe is because there is no active window with the OLE control to process the pdf.

Never see this type of situation before. My application is not designed to run as a service.

Maybe is something at the Windows 2003 SP2 OS level.
hector g pabon
User
 
Posts: 13
Joined: Fri Feb 17, 2012 3:33 am

Re: Overaly example dt109941.app and print PDF direct to Pri

Postby Tracker - Clarion Support on Sat Feb 25, 2012 2:39 pm

Hi Hector!

Using Clarion, you must have open a Window with the OLE control on it to use the Viewer ActiveX. There are other ways of activating some ADO/ActiveX controls without a Window, but not ours; it's a Viewer and requires a Window even if you don't have to "see" the control.
Craig Ransom
Tracker Software - Clarion Support
http://www.tracker-software.com
Tracker - Clarion Support
Site Admin
 
Posts: 1351
Joined: Wed Jun 30, 2004 4:45 pm
Location: Maryland, USA

Re: Overaly example dt109941.app and print PDF direct to Pri

Postby hector g pabon on Sat Feb 25, 2012 8:56 pm

Hi Craig,

Solved! The ActiveX was not registered correctly.

Thanks for help.
hector g pabon
User
 
Posts: 13
Joined: Fri Feb 17, 2012 3:33 am

Re: Overaly example dt109941.app and print PDF direct to Pri

Postby Tracker - Clarion Support on Sat Feb 25, 2012 10:09 pm

Hi Hector!

Could you please tell me exactly what you did to register the ActiveX?
Craig Ransom
Tracker Software - Clarion Support
http://www.tracker-software.com
Tracker - Clarion Support
Site Admin
 
Posts: 1351
Joined: Wed Jun 30, 2004 4:45 pm
Location: Maryland, USA

Re: Overaly example dt109941.app and print PDF direct to Pri

Postby hector g pabon on Sat Feb 25, 2012 10:55 pm

Hi Craig,

I did the following:

RUN PDFXCview.exe /RegServer
RUN regsvr32.exe PDFXCviewAx.dll
hector g pabon
User
 
Posts: 13
Joined: Fri Feb 17, 2012 3:33 am

Re: Overaly example dt109941.app and print PDF direct to Pri

Postby Tracker - Clarion Support on Sun Feb 26, 2012 3:32 am

Hi Hector!

Thanks! I asked because PDFXV_dev.exe is SUPPOSED to install and register the ActiveX components, but there has been some indication that this is not working as intended.
Craig Ransom
Tracker Software - Clarion Support
http://www.tracker-software.com
Tracker - Clarion Support
Site Admin
 
Posts: 1351
Joined: Wed Jun 30, 2004 4:45 pm
Location: Maryland, USA


Return to PDF-Tools SDK (DLL Libraries Only) - Clarion For Windows Developers Only Please

Who is online

Users browsing this forum: No registered users and 0 guests