|
-
Jun 8th, 2007, 09:00 AM
#1
Thread Starter
Addicted Member
[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
Last edited by caffeine; Jun 8th, 2007 at 09:01 AM.
Reason: Listed borders twice
-
Jun 8th, 2007, 09:06 AM
#2
New Member
Re: Duplicating a Worksheet
Yes.
Code:
Sheets(1).Copy Before:=Sheets(2)
-
Jun 8th, 2007, 10:24 AM
#3
Hyperactive Member
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.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|