Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Help printing to PDF file
I have a macro that currently creates 800+ custom 2-page
reports for different vendors off a large database. The first two tabs in my workbook represent the first and second page of each report. The macro goes through the list of 800 vendors, grabs the data that pertains to them (located on different tabs of the workbook), places it in an area that produces the graphs and summary charts for that vendor, prints that vendor's report, erases the data in the form, and proceeds to the next vendor. I have been asked to produce PDF files for each vendor instead of paper copies. I thought this would be an easy conversion, but when the printer is set to PDF, a new dialog box opens when the following code executes: 'Print page 1 Sheets("Report 1").Select ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True 'Print page 2 Sheets("Report 2").Select ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True The dialog box is titled "Save PDF File As" and it defaults to naming the PDF file with the first prefex as the excel file. I can easily change that, except I can't find any macro syntax that can either bypass this dialog box by naming the file directly. I also can't figure out how to write code that will accept the default file name that is offered in this dialog box. I suspect that the dialog box has been created by Adobe, but they can't help me. This issue here is automation--I don't want someone sitting at a computer pressing "yes" 800 times to accept the default when I should be able to set a few parameters within the subroutine and then walk away for four hours. Any ideas? I already approached Adobe thinking they would have encountered this issue before, but they had no suggestions. |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Printing to a PDF file | Excel Discussion (Misc queries) | |||
Printing to PDF file... | Excel Discussion (Misc queries) | |||
printing to file | New Users to Excel | |||
printing to pdf file | Excel Worksheet Functions | |||
printing to a PDF file | Excel Programming |