[RESOLVED] Duplicating a Worksheet
Is there an efficient way of duplicating a worksheet in another workbook?
I don't mean just values -- everything. Values, borders, row heights, column widths, graphics, graphic settings (e.g. "don't move or size with cells"), cell interior colors, etc.
Thanks!
Pete
Re: Duplicating a Worksheet
Yes.
Code:
Sheets(1).Copy Before:=Sheets(2)
Re: Duplicating a Worksheet
If you want it in another workbook, it would look like
Worksheets(SheetName).Copy Before:=Workbooks(WorkbookName).Sheets(1)
Middle of this thread may help too...
http://vbforums.com/showthread.php?t=469042
As you need to open WorkbookName first, copy, and then close that workbook... Also have to splice WorkbookName, if you just know the path of it.