converting an office file to .pdf

jwbrooks99

New member
Local time
Today, 10:35
Joined
Mar 31, 2009
Messages
7
VBA newby..... I am busy coding a document management system. I store the path of the document in a table. I managed to get the application to upload office files to a target directory and view them. I currently open the files using it's default application e.g .doc in MS Word etc. I would like to open the stored files in pdf format. In other words I would like to retain the original document format where it is stored but viewing it with a command button that converts (a copy) the file to .pdf format. I have downloaded pdfcreator and some code samples but cannot figure out a way of doing this.
 
Hello,

I guess that you could print the document through vba to the "pdfCreator" printer. Unfortunately I do not know if there's a way to bypass the two pdfCreator windows that will pop up (asking for pdf file name, attributes and path).

Have you considered opening the doc file in read only mode? This is what I did when I encountered the same problem:

Code:
Set officeDoc = officeApp.Documents.Open(FileName:=CurrentProject.Path & _
        FormsFolder & "\" & docName & ".doc", ReadOnly:=True, _
        Visible:=True)
 

Users who are viewing this thread

Back
Top Bottom