![]() |
|
|
|||||||
| Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
![]() |
|
|
Thread Tools | Rate Thread | Display Modes |
|
|
#1 |
|
Registered User
Join Date: Oct 2004
Posts: 2
|
****o I am currently trying to convert Word Documents to PDF using Visual Basic 6.0 and the code Im using seems to be converting the document, but when I try to open the pdf I get this message: Adobe Reader could not open 'BSXC70.pdf' because it is either not a supported file type or because the file has been corrupted. BSX70 is the name of the pdf. However, if I do it manually from Word, it works fine. The code Im using is as follows: objWordDoc.PrintOut Background:=0, Range:=wdPrintAllDocument, outputFilename:="C:\My Documents\PDF Files Test\BSX70.pdf", Item:=wdPrintDocumentContent, Copies:=1, pagetype:=wdPrintAllPages, PrintToFile:=True, collate:=False objWordDoc is the word document to change to pdf. I tried it with just the Background and Range, eliminating the Output File Name and when I ran the program I got the Primo PDF screen that asks for a "save as" destination. I entered the folder path and it worked fine using the vb script. But the idea is to have the program select the destination path in code. I dont know if this is too technical, but any help would be apreciated. Thanx. |
|
|
|
|
|
#2 | |
|
Director of Engineering
Join Date: Feb 2004
Posts: 304
|
Quote:
What you are doing is creating a postscript file from the word doc object. There is no conversion to PDF taking place in your code. There is also no API to Primo so you will not be able to do this programmatically. There is an application called "Server" available at www.activepdf.com that will do exactly what you're looking for and provides an example of this exact scenario in the documentation.
__________________
------------------------------------- Douglas Saltsman ActivePDF Leading the iPaper revolution --------------------------------------- |
|
|
|
|
|
|
#3 |
|
Registered User
Join Date: Oct 2004
Posts: 2
|
Mesage Recieved
****o Douglas
Thank's for the info and the quick reply. RARTIGAS |
|
|
|
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|