ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Removing Dialog Box (https://www.excelbanter.com/excel-programming/307321-removing-dialog-box.html)

No Name

Removing Dialog Box
 
Hi,

I have a macro that involves deleting a sheet. However a
dialog box asking whether the user should proceed with
deletion appears, which is very annoying for users. Is
there a way to stop this from appearing, either
programmatically or by altering settings.

I am using Excel 2002 and VBA.

Thanks in Advance

Tom Ogilvy

Removing Dialog Box
 
Application.DisplayAlerts = False
activesheet.Delete
Application.DisplayAlerts = True

--
Regards,
Tom Ogilvy

wrote in message
...
Hi,

I have a macro that involves deleting a sheet. However a
dialog box asking whether the user should proceed with
deletion appears, which is very annoying for users. Is
there a way to stop this from appearing, either
programmatically or by altering settings.

I am using Excel 2002 and VBA.

Thanks in Advance




No Name

Removing Dialog Box
 
Thanks for the quick response!

Cheers

-----Original Message-----
Application.DisplayAlerts = False
activesheet.Delete
Application.DisplayAlerts = True

--
Regards,
Tom Ogilvy

wrote in message
...
Hi,

I have a macro that involves deleting a sheet. However a
dialog box asking whether the user should proceed with
deletion appears, which is very annoying for users. Is
there a way to stop this from appearing, either
programmatically or by altering settings.

I am using Excel 2002 and VBA.

Thanks in Advance



.



All times are GMT +1. The time now is 12:13 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com