Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 18
Default How-To suppress a warning dialog

Dear Experts

I am trying to delete all but one worksheetsheet
named "products" in active workbook. When ever I try
running the macro a Warning pops up asking All content of
the sheet would be lost, do you wish to continue (or
something like this)
Is there a way to prevent that from poping up.
Please advise

I use xl2002 vba on Win 2k

Thanks
James
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,885
Default How-To suppress a warning dialog

Hi
try
application.displayalerts=false
'your code
application.displayalerts=true

--
Regards
Frank Kabel
Frankfurt, Germany


James wrote:
Dear Experts

I am trying to delete all but one worksheetsheet
named "products" in active workbook. When ever I try
running the macro a Warning pops up asking All content of
the sheet would be lost, do you wish to continue (or
something like this)
Is there a way to prevent that from poping up.
Please advise

I use xl2002 vba on Win 2k

Thanks
James

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default How-To suppress a warning dialog

Insert

Application.DisplayAlerts = False

before the deletes and then

Application.DisplayAlerts = True

after.



--
Message posted from http://www.ExcelForum.com

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Suppress dialog from regserver command mdullni1 via OfficeKB.com Excel Discussion (Misc queries) 3 April 30th 08 07:51 PM
how to suppress office assistance dialog Ormy Excel Discussion (Misc queries) 0 January 20th 06 09:49 AM
Macro Help - Suppress warning box ssmith Excel Programming 3 July 20th 04 08:07 PM
Suppress dialog while opening a write protected Excel document from VBS Stefan[_7_] Excel Programming 1 February 17th 04 12:47 PM
Unable to suppress warning message... Jeff Richman Excel Programming 3 October 31st 03 07:25 AM


All times are GMT +1. The time now is 04:55 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"