Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Need to programmatically convert and merge a .doc and a .tif to .pdf using original Adobe 'writer'

Posted on 2008-06-10
4
Medium Priority
?
871 Views
Last Modified: 2013-12-04
Hi,

there is a scanned file (in TIFF format) and a stored Word document (.DOC). Both files should be merged together into one PDF File using the ADOBE Acrobat Professional 7.0. The conversion must run automatically (on a server) without user input.

I recently tried to achieve that by using ImageMagick but the project requires usage of Acrobat Writer rather than a third-party product.

Regards, Alex
0
Comment
Question by:itsmeandnobodyelse
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
4 Comments
 
LVL 39

Author Comment

by:itsmeandnobodyelse
ID: 21795585
As far as I evaluated there are a few ways to achieve the above, none of them really comfortable:

1. Usage of ADOBE PDF Library SDK  

The caveat is that - opposite to Acrobat Prof. executable, the PDF library SDK has no filters included which would convert standard filetypes like .doc to PDF. I neither know til now whether it could take a .tif file as input or if I have to use other tools to achieve that. The .doc must be *printed* to a PDF or postscript file using Word automation (what most likely will slow down the process significantly).

2. Usage of  Acrobat Prof. by means of OLE (and DCOM)

With that I could do all conversions required as Acrobat Prof.  has all filters included. But, as there is no C++ wrapper for the interface and I didn't find a good documentation on the OLE interface till now.

3. Using the Javascript interface provided by Adobe

Most likely it doesn't include conversion filters either. And actually I don't think that invoking Javascript from C++ is a senseful solution.

4. Adding a self-written plug-in to Acrobat and invoke it via DCOM

That has some charme as one of the samples Adobe provided with its plug-in support, does pretty much what I need. Unfortunately I neither know how to add a self-written plugin with .api extension to Acrobat Prof.  nor how to call and pass arguments to it using DCOM.  

0
 
LVL 86

Accepted Solution

by:
jkr earned 2000 total points
ID: 21810061
Any chance you can skip the requirement "Adobe 'writer'"? With GhostScript and some tricks (including MS Office installed on the server), that should be feasible... (not that I would promise anything here right now ;o)
0
 
LVL 39

Author Comment

by:itsmeandnobodyelse
ID: 21810282
>>>> Any chance you can skip the requirement "Adobe 'writer'"?
No, I had a solution using ImageMagick which converts the tif and takes text. But then, the customer wants to have a .doc instead of plain text and the final should be all input resized to 90 percent into a 'frozen' pdf created by acrobat. The customer is a bank and they need to have it archived untouchable for at least 10 years. They only trust original Adobe software to guarantee that.

Thanks for your answer.

0
 
LVL 39

Author Comment

by:itsmeandnobodyelse
ID: 21888479
We were currently trying to go alternative 4 (adding a self-written plug-in to Acrobat and invoke it via DCOM). We achieved to build and add the PDFBinder plug-in (by simply copying it into the plug-ins folder) and found a code sample (Code Project) how to invoke a plug-in of Acrobat(MFC and C++). Though our app doesn't use MFC framework we nevertheless can use MFC and next week it will turn out whether we could go that way.

I'll close the question in a few days.
0

Featured Post

New benefit for Premium Members - Upgrade now!

Ready to get started with anonymous questions today? It's easy! Learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Update 21-May-2015: I temporarily removed the source code and the code snippets to make major changes to the program. Regards, Joe INTRODUCTION This Article is a follow-up to the Article entitled How To Rename-Move a Batch of PDF Files Based o…
The Adobe PDF proprietary file format is recognized as secure and formulated. But these PDF files are also prone to corruption and any external threat like virus attacks, improper storage can hit PDF file integrity.This type of damages can make cruc…
The goal of the video will be to teach the user the concept of local variables and scope. An example of a locally defined variable will be given as well as an explanation of what scope is in C++. The local variable and concept of scope will be relat…
The viewer will be introduced to the member functions push_back and pop_back of the vector class. The video will teach the difference between the two as well as how to use each one along with its functionality.

670 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question