![]() |
Code to open new workbook, prompt for 'save as' name.
I have created extensive code to derive reports off a current workbook.
What I want to do now is create a macro in my original workbook that will open a new workbook, run my report code, and then prompt for a save_as name. The most important part is really just getting a macro to open a new workbook. I realize the code for my report generating will need to be modified to refer to the correct pages. |
Code to open new workbook, prompt for 'save as' name.
To get a new workbook you can use code similar to
dim wbk as workbook set wbk = workbooks.add To save this new workbook you can use wbk.saveas "C:\MyBook.xls" HTH "Mark" wrote: I have created extensive code to derive reports off a current workbook. What I want to do now is create a macro in my original workbook that will open a new workbook, run my report code, and then prompt for a save_as name. The most important part is really just getting a macro to open a new workbook. I realize the code for my report generating will need to be modified to refer to the correct pages. |
All times are GMT +1. The time now is 06:40 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com