hi there...
having a bit of trouble this one...i have a workbook a dynamic amount of worksheets...my goal is to delete all sheets except a sheet named "Blank".
i thought a if then would do it but struggling wiht it.
here is the code
having a bit of trouble this one...i have a workbook a dynamic amount of worksheets...my goal is to delete all sheets except a sheet named "Blank".
i thought a if then would do it but struggling wiht it.
here is the code
Code:
For Each shtD In wrkD.Worksheets
If shtD.Name = "Blank" Then
Next shtD
Else
shtD.Delete
Next shtD