ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Auto Acknowedge a prompt box? (https://www.excelbanter.com/excel-programming/355645-auto-acknowedge-prompt-box.html)

tarns[_5_]

Auto Acknowedge a prompt box?
 

My vba macro does some deleting of columns and i wish to turn off the
feature where the dialog box prompts me to click 'OK' to delete the
data everytime i run my macro.

I used this code:
'Turn off prompts
DisplayAlerts = False

But no luck.... can someone help me out?


--
tarns
------------------------------------------------------------------------
tarns's Profile: http://www.excelforum.com/member.php...o&userid=32291
View this thread: http://www.excelforum.com/showthread...hreadid=520946


NickHK

Auto Acknowedge a prompt box?
 
tarns,
Now you see the benefit of "Option Explicit" at the top of all code.
It "does not work" because you are not affecting Excel; you are setting your
own variable called DisplayAlerts to False

Check the Help for the correct syntax.

NickHK

"tarns" wrote in
message ...

My vba macro does some deleting of columns and i wish to turn off the
feature where the dialog box prompts me to click 'OK' to delete the
data everytime i run my macro.

I used this code:
'Turn off prompts
DisplayAlerts = False

But no luck.... can someone help me out?


--
tarns
------------------------------------------------------------------------
tarns's Profile:

http://www.excelforum.com/member.php...o&userid=32291
View this thread: http://www.excelforum.com/showthread...hreadid=520946





All times are GMT +1. The time now is 08:36 AM.

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