ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Similar PDF generation Problem (https://www.excelbanter.com/excel-programming/359281-similar-pdf-generation-problem.html)

CINDY

Similar PDF generation Problem
 
Hello All,

I have aproblem similar to many I've read on generating a PDF to a filename,
but the suggestions for the other posts that I've read don't seem to be
working for me.

Any help would be greatly apprecited.

I'm using Excel 2003 SP1 & Adobe Acrobat 7.0 Professional version 7.0.7

What's happening: I get a Preview File that looks fine. But when I try to
open the file generated, I get the message "Acrobat could not open
'di02000_cp1.pdf' because it is either not a supported file type or because
the file has been damaged.....To create an Adobe PDF document, go to the
source applicatio. Then print the document to Adobe PDF."

Here is my code:
Sub PrintPDF()

directory2use = "\\dsks48\process\"
filename2use = directory2use + "di02000_cp1.pdf"

Application.ActivePrinter = "Adobe PDF on Ne03:"
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Preview:= _
True, ActivePrinter:= "Adobe PDF on Ne03:", PrintToFile:= _
True, Collate:=True, PrToFilename:=filename2use
End Sub


Any suggestions?

Thanks in advance,
Cindy W.


All times are GMT +1. The time now is 02:36 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com