G
Guest
In my code after my DIM statements I have:
On Error GoTo wsAdd
With Sheets("MySummary")
.Activate
.Cells.ClearContents
End With
Let's say MySummary (sheet) does not exist - so macro jumps to:
wsAdd:
Sheets.Add after:=Sheets(Sheets.Count)
ActiveSheet.Name = "MySummary"
On Error GoTo 0
Resume Next '<< Creates and Names Sheet MySummary
an returns to the line:
.Activate << Where the Macro Bombs -- What is wrong??
On Error GoTo wsAdd
With Sheets("MySummary")
.Activate
.Cells.ClearContents
End With
Let's say MySummary (sheet) does not exist - so macro jumps to:
wsAdd:
Sheets.Add after:=Sheets(Sheets.Count)
ActiveSheet.Name = "MySummary"
On Error GoTo 0
Resume Next '<< Creates and Names Sheet MySummary
an returns to the line:
.Activate << Where the Macro Bombs -- What is wrong??