I'm using the following code and it works great except for the dialog box that pops up for each sheet deleted.
How can I edit the code do automatically select the delete button on the pop-up
Sub Delete_Multiple_Excel_Worksheets()
Set ws1 = Worksheets("Parameters").Range("D2")
Set ws2 = Worksheets("Parameters").Range("D3")
Set ws3 = Worksheets("Parameters").Range("D4")
'delete three worksheets at the same time
Worksheets(ws1.Value).Delete
Worksheets(ws2.Value).Delete
Worksheets(ws3.Value).Delete
End Sub
How can I edit the code do automatically select the delete button on the pop-up
Sub Delete_Multiple_Excel_Worksheets()
Set ws1 = Worksheets("Parameters").Range("D2")
Set ws2 = Worksheets("Parameters").Range("D3")
Set ws3 = Worksheets("Parameters").Range("D4")
'delete three worksheets at the same time
Worksheets(ws1.Value).Delete
Worksheets(ws2.Value).Delete
Worksheets(ws3.Value).Delete
End Sub