copy and paste data (includes groups...)
I always do worksheet copies like this
Workbooks(NewBook).Sheets("a").cells.Copy _
destination:= Workbooks(Activebook).Sheets("b").cells
Maybe you just want to delete the old sheet and the copy entiore sheet this
copies more info
Workbooks(Activebook).Sheets("b").Delete
Workbooks(NewBook).Sheets("a").Copy _
after:=Workbooks(Activebook).Sheets(1)
ActiveWorkbook.Name = "b"
"Miri" wrote:
hi,
i need to copy spesific sheet from one workbook to another existing sheet in
other workbook.
both sheets includes Grouping.
i wrote a code that copy and paste, but the actual result is that the
grouping at the end is not related to the new data i pasted.
what should i add to my code in order to copy also the groups.
my code:
Workbooks(NewBook).Sheets("a").Cells.Select
Selection.Copy
...
Workbooks(Activebook).Sheets("b").Select
Range("A1").PasteSpecial Paste:=xlPasteAll
--
Miri Tz.
|