ERLANDSEN DATA CONSULTING Excel & VBA Tips   Informasjon på norsk / Information in Norwegian


These pages are no longer updated and are only available for archive purposes.
Click here to visit the pages with updated information.

Turn off warning messages

Sometimes the application displays a messagebox asking if the user wants to continue, if he/she wants to save a file before closing, or want some other verification from the user. These messages can be turned off by using this command in a macro :

Application.DisplayAlerts = False

The warningmessages will remain turned off until you enable them again with this command:

Application.DisplayAlerts = True

If you just want to close a workbook without the user being prompted for any confirmations about saving the workbook you can simply do this:

ActiveWorkbook.Close False 
' closes the active workbook without saving any changes

ActiveWorkbook.Close True 
' closes the active workbook and saves any changes

 

Document last updated 2000-02-05 12:47:32      Printer friendly version

User Contributed Comments (in descending order):
Ole P. from Norway wrote (2003-09-09 12:29:24 CET):
Re: En Otro Idioma
I have a limited knowledge of Spanish (and other languages), so this site will only be available in English and Norwegian.
Ricardo Salinas from Santiago de Chile wrote (2003-09-08 23:16:15 CET):
En Otro Idioma
Hola, buena pagina, me gustaria saber si existe la posibilidad que esta pagina este en Español.

Saludos,
Ricardo Salinas
Santiago de Chile

<< Previous  1  2  Next >>


F1 from ExcelTip.com

Erlandsen Data Consulting     http://www.erlandsendata.no/   
Excel & VBA Tips   Copyright ©1999-2010    Ole P. Erlandsen   All rights reserved
E-mail Contact Address