Logo 
Search:

MS Office Answers

Ask Question   UnAnswered
Home » Forum » MS Office       RSS Feeds
  Question Asked By: Lucina Ferrrari   on Feb 18 In MS Office Category.

  
Question Answered By: Alok Iit   on Feb 18

If the workbook  has never been saved as an xls file then closing it
without saving it means it won't exist and so it will not have to be
deleted!
The following vba code should quit excel completely:

Application.DisplayAlerts = False
Application.Quit

This next bit should close a workbook without saving:

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

or if you don't know the name of the workbook:

Thisworkbook.Close SaveChanges:=False

Share: 

 

This Question has 1 more answer(s). View Complete Question Thread

 
Didn't find what you were looking for? Find more on Delete open workbook Or get search suggestion and latest updates.


Tagged: