R
Ray Kanner
The following simple macro (printing out a range called
POut) to a file Sample05.pdf shown here
Sub Macro1()
Application.ActivePrinter = "Acrobat PDFWriter on LPT1:"
Range("POut").PrintOut Copies:=1, _
ActivePrinter:="Acrobat PDFWriter on LPT1:", _
PrToFileName:="Sample05.pdf"
End Sub
gives me an Acrobat PDF Writer Error "Cannot print, file
is already in use or locked", and then a run-time
error '1004' telling me it couldn't be printed due to an
error on Acrobat PDFWriter. The same thing happened when I
tried printing to Distiller instead of PDFWriter. The
Sample05.pdf does not exist prior to running the macro and
I have no trouble sending it to the printer manually from
within Excel.
Thanks in advance.
Ray
POut) to a file Sample05.pdf shown here
Sub Macro1()
Application.ActivePrinter = "Acrobat PDFWriter on LPT1:"
Range("POut").PrintOut Copies:=1, _
ActivePrinter:="Acrobat PDFWriter on LPT1:", _
PrToFileName:="Sample05.pdf"
End Sub
gives me an Acrobat PDF Writer Error "Cannot print, file
is already in use or locked", and then a run-time
error '1004' telling me it couldn't be printed due to an
error on Acrobat PDFWriter. The same thing happened when I
tried printing to Distiller instead of PDFWriter. The
Sample05.pdf does not exist prior to running the macro and
I have no trouble sending it to the printer manually from
within Excel.
Thanks in advance.
Ray