mikechambers
Active Member
- Joined
- Apr 27, 2006
- Messages
- 397
I am using Excel 2003 and I have the full version of Adobe Acrobat 8 Standard, not the Microsoft plugin. I am just trying to export a workbook to a PDF using VBA. I have tried the following:
Sheets(Array("Sheet1", "Sheet2", "Sheet3")).Select
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
However, the problem is that I can't get it to include all sheets in the workbook in the SAME PDF. It was to make each spreadsheet a separate PDF file. Even without using VBA, I can't get it to work if I am just Printing it to the PDF Writer. I have selected Entire Workbook, All Active Sheets, All Selected Sheets, nothing works. Now if I just click the Adobe button on the toolbar, it works just fine, but again, I am trying to put this at the end of a sub routine so it finishes as a PDF. Any suggestions?
Sheets(Array("Sheet1", "Sheet2", "Sheet3")).Select
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
However, the problem is that I can't get it to include all sheets in the workbook in the SAME PDF. It was to make each spreadsheet a separate PDF file. Even without using VBA, I can't get it to work if I am just Printing it to the PDF Writer. I have selected Entire Workbook, All Active Sheets, All Selected Sheets, nothing works. Now if I just click the Adobe button on the toolbar, it works just fine, but again, I am trying to put this at the end of a sub routine so it finishes as a PDF. Any suggestions?