I have a simple macro, that adds a sheet to a workbook. However, sometimes I have to delete some sheet(s). When I delete a sheet and I use the macro again, the newly added sheet assumes the number which follows, as if the deleted sheets are stil present. I want that the macro adds a sheet with the next number. For example I have:
Sheet1 Sheet2 Sheet3
Then I delete Sheet3
and want to add another sheet, which perfectly will be Sheet3
and not Sheet4
With ThisWorkbook
.Sheets.add After:=.Sheets(.Sheets.Count)
End With
How can I do this?