create copy of sheet tab (excel 2007) when opening workbook

  • Thread starter Thread starter jatman
  • Start date Start date
J

jatman

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
 
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 Before:=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 Before:=Sheets("Sheet1")

The newly inserted sheet will become the active sheet.

Hope this helps some
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top