![]() |
create copy of sheet tab (excel 2007) when opening workbook
i have a purchase order with three tabs and it works great.
but i have a new purchase order but when it opens, i want it to create anoter copy of the first tab "Purchase Order" on which the user would enter the required information, leaving the original sheet in tact. any help in this macro would be appreciated. jat |
create copy of sheet tab (excel 2007) when opening workbook
This is a simple one-liner, choose which one would be best for you:
To put the new sheet at the beginning of the book: Sheets("Sheet1").Copy Befo=Sheets(1) or to put it at the end of the book Sheets("Sheet1").Copy after:=Sheets(Sheets.Count) If you want to put it in front of a particular existing sheet (such as Sheet1 itself) Sheets("Sheet1").Copy Befo=Sheets("Sheet1") The newly inserted sheet will become the active sheet. Hope this helps some "jatman" wrote: i have a purchase order with three tabs and it works great. but i have a new purchase order but when it opens, i want it to create anoter copy of the first tab "Purchase Order" on which the user would enter the required information, leaving the original sheet in tact. any help in this macro would be appreciated. jat |
All times are GMT +1. The time now is 04:25 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com