Hi All

I use a print driver based software package to convert my files to PDFs.
The code below prgramatically converts the doc to a pdf. It opens a save as
dialog which then requires me to enter a filename. It then saves the doc as
apdf under the filename that I entered.

Does anyone know if or how I can alter this code so that the value of a
specific variable is pre-entered as the filename? Or better still not even
open the dialog, just save it directly to the correct location under the
correct file name.

Any pointers would be appreciated.

ActivePrinter = "PDF995"
Application.PrintOut FileName:="", Range:=wdPrintAllDocument, Item:= _
wdPrintDocumentContent, Copies:=1, Pages:="",
PageType:=wdPrintAllPages, _
Collate:=True, Background:=False, PrintToFile:=False,
PrintZoomColumn:=0, _
PrintZoomRow:=0, PrintZoomPaperWidth:=0, PrintZoomPaperHeight:=0


'restore printer to default
'ActivePrinter = "Printer1"

Re: Automating the filename for pdf conversion by Doug

Doug
Tue Aug 15 11:55:04 CDT 2006

There is usually an option in the .pdf conversion software to prompt for a
filename or not.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Gem_man" <Gemman@discussions.microsoft.com> wrote in message
news:DF7DFFFB-BC2D-4B43-A1DC-0550B6ACBCB5@microsoft.com...
> Hi All
>
> I use a print driver based software package to convert my files to PDFs.
> The code below prgramatically converts the doc to a pdf. It opens a save
> as
> dialog which then requires me to enter a filename. It then saves the doc
> as
> apdf under the filename that I entered.
>
> Does anyone know if or how I can alter this code so that the value of a
> specific variable is pre-entered as the filename? Or better still not
> even
> open the dialog, just save it directly to the correct location under the
> correct file name.
>
> Any pointers would be appreciated.
>
> ActivePrinter = "PDF995"
> Application.PrintOut FileName:="", Range:=wdPrintAllDocument, Item:= _
> wdPrintDocumentContent, Copies:=1, Pages:="",
> PageType:=wdPrintAllPages, _
> Collate:=True, Background:=False, PrintToFile:=False,
> PrintZoomColumn:=0, _
> PrintZoomRow:=0, PrintZoomPaperWidth:=0, PrintZoomPaperHeight:=0
>
>
> 'restore printer to default
> 'ActivePrinter = "Printer1"
>