View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
ezil ezil is offline
external usenet poster
 
Posts: 43
Default display alerts= false not working

Display alerts = false is not working suddenly. Previously when I use in
macros it was working. So I tried following example then also it gives the
alert message
"save changes yes or no?" e.g 2 also gives alert message

Example
This example closes the workbook Book1.xls and doesnt prompt the user to
save changes. Any changes to Book1.xls arent saved.

Application.DisplayAlerts = False
Workbooks("BOOK1.XLS").Close
Application.DisplayAlerts = True

eg:2 Workbooks("BOOK1.XLS").Close SaveChanges:=False