Hi All.
I create code that generate copy of a worksheet:
It is working. But when I want to create a new sheet on the same date, in this case, the sheet will be created but an error message will pop up. How to resolve this error message?Sub CopySheet() Dim ws As Worksheet ActiveSheet.Copy After:=Sheets(Sheets.Count) Set ws = Sheets(Sheets.Count) ws.Name = Format(Date, "mm-dd-yy") End Sub
Thanks
Bookmarks