Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Problems to convert document into pdf

Status
Not open for further replies.

botte

Programmer
Jun 24, 2002
6
CH
Hello

I try to convert a .doc-file into a .pdf-file using an object called ACRODISTXLib.PdfDistiller with the following code:

Public WithEvents oDist As ACRODISTXLib.PdfDistiller

function printPDF()
Dim result As Integer

set odist = New ACRODISTXLib.PdfDistiller
result = oDist.FileToPDF _("mypath\titi.doc", "mypath\titi.pdf", "")



This code seems to run.
The status window of the Distiller appears and desappears and result returns 1, which means the convertion to pdf succeed.

But my titi.pdf hasn't been created!
Instead of this, i get a titi.dic (text document) in which I may read the following very helpful sentences:

%%[ Error: undefined; OffendingCommand: ÐÏࡱá ]%%
%%[ Flushing: rest of job (to end-of-file) will be ignored ]%%
%%[ Warning: PostScript error. No PDF file produced. ] %%

Hmmm

Perhaps this comes from the fact that I'm working on Access 97 ...
And perhaps someone could help me ...

However ... Have a great summer



 
Please Waldemar,

Could you be more explicit?

Flo
 
Quoting some other forums's note:

"We created these files with a Adobe Driver 4.2 and have created 11 X 17 maps. We have tried to open these same files with Adobe Distiller and it is also unable to open and convert to PDF. After looking into the problem we discovered an advanced setting for the driver which changes the data format to ASCII. The default format which we used was "tagged binary communication protocol". When we used the ASCII format distiller could read in the file and create a PDF but photoshop was still unable to read it."

Really interesting would be the error code after "Error: undefined; OffendingCommand:" ÐÏࡱá

Regards
 
If I remember correctly (I actually got so frustrated that I purchased third party code that works beautifully) you need to use an intermediate step when going from a .doc to a .pdf... The distiller requires a post script file.. you need to convert the word doc to a post script file and then convert the post script file to a pdf. It is much easier to use the pdfmaker library if you don't need all of the power of the distiller.

We generate invoices as pdfs (from access reports or word docs) so that they can be emailed to customers.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top