Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I've changed it to
Application.DisplayAlerts = False On Error Resume Next Sheets("Sheet1").Delete Application.DisplayAlerts = True and all is good with the world. Thanks for your help. "Tushar Mehta" wrote: Use the untested Sub DeleteSheet() On Error Resume Next Sheets("Sheet1").Delete End Sub -- Regards, Tushar Mehta www.tushar-mehta.com Excel, PowerPoint, and VBA add-ins, tutorials Custom MS Office productivity solutions In article , says... I have this simple macro Sub DeleteSheet() Sheets("Sheet1").Select ActiveWindow.SelectedSheets.Delete End Sub How should I modify it so that if Sheet1 isn't present, it'll just move on. I'll want to add more to this at a later time, so Exit Sub may not necessarily be an option. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Quick question on Error Trapping | Excel Programming | |||
Error Trapping | Excel Programming | |||
error trapping | Excel Programming | |||
trapping error | Excel Programming | |||
error trapping | Excel Programming |