Hi,
I tried to copy selected worksheet to new WorkBook. But during the operation CELLs/COLUMN/ROW COLOR have been changed :/
Do you know why or how to resolve the issue?
I tried to copy selected worksheet to new WorkBook. But during the operation CELLs/COLUMN/ROW COLOR have been changed :/
Code:
For Each ws In wb.Sheets
next_ws = ws.Name
If dict_sheet.exists(next_ws) Then
If next_ws = "Sam" Then
Set NewBook = Workbooks.Add
ws.Copy Before:=NewBook.Sheets(1)
NewBook.Worksheets("Sam").Cells.Select
Selection.Copy
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks:=False, Transpose:=False
Range("A1").Select
Else if....
etc....
End if
End if
Next
Do you know why or how to resolve the issue?