>Can I run pdfmaker programatically from within a protected
>form?
Recording the menu actions produced this macro line:
Application.Run MacroName:="AdobePDFMakerA.AutoExec.ConvertToPDF"
However, I find that printing to the Distiller Printer is more to my
liking:
Here are some code fragments that might help:
' Requires a Reference to "Acrobat Distiller" (ACRODIST.EXE)
Dim myPDF As New PdfDistiller ' Class PDFDistiller
Dim oldPrinter As String
oldPrinter = ActivePrinter
' Select a printer without changing the system default printer:
With Dialogs(wdDialogFilePrintSetup)
.Printer = "Acrobat Distiller"
.DoNotSetAsSysDefault = True
.Execute
End With
' Next two statements control name of PDF file.
Application.PrintOut OutputFileName:=myPath & myFilename & ".ps", _
PrintToFile:=True, Background:=False
myPDF.FileToPDF myPath & myFilename & ".ps", "", _
theFolder & "\eBook-WebReports.joboptions"
' Select a printer without changing the system default printer:
With Dialogs(wdDialogFilePrintSetup)
.Printer = oldPrinter
.DoNotSetAsSysDefault = True
.Execute
End With
' Restore "PrintToFile" back to false by printing nothing!
' See: http://www.mvps.org/word/FAQs/MacrosVBA/ResetPrintToFile.htm
Application.PrintOut Range:=wdPrintRangeOfPages, Pages:="0", _
PrintToFile:=False
Set myPDF = Nothing
Good luck.
--
Michael Bednarek, IT Manager, Tactical Global Management
Waterfront Pl, Brisbane 4000, Australia. "POST NO BILLS"
http://mcmbednarek.tripod.com/
It isn't what he was wanting, because PDFMaker isn't a separate executable,
it is a macro supplied by Adobe in an add-in.
--
Regards
Jonathan West - Word MVP
MultiLinker - Automated generation of hyperlinks in Word
Conversion to PDF & HTML
http://www.multilinker.com
I would also like to run pdfMaker in batch to create a
series of pdf's from word.doc's creating bookmarks for
word styles automatically.
>.
>
I already gave you a detailed answer to the same question you asked in the
userforms group. Please don't post multiple copies of the same question in
different groups, it makes it harder both for you and for the volunteers who
answer these questions to keep track of what has been answered and what
hasn't.
--
Regards
Jonathan West - Word MVP
MultiLinker - Automated generation of hyperlinks in Word
Conversion to PDF & HTML
http://www.multilinker.com
"michael Hall" <michae...@dot.state.wi.us> wrote in message
news:081401c3820b$1ed766b0$a101...@phx.gbl...