This is what I am using:
If mutiple workbooks are open I just want it to close this one workbook
If only one workbook is open then i want it to close the workbook and exit the excel. The issue i'm having is that if only one workbook is open it does exit the workbook.. but it leaves me in excel with the grey background.. so pretty much my application.quit doesnt seem to be working if only one workbook is open. Any idea on whats wrong?
Code:
'// Exit Everything... Save? No Not Needed....
Application.DisplayAlerts = False
ActiveWorkbook.Close
If Application.Workbooks.Count = 1 Then
Application.Quit
End If
If mutiple workbooks are open I just want it to close this one workbook
If only one workbook is open then i want it to close the workbook and exit the excel. The issue i'm having is that if only one workbook is open it does exit the workbook.. but it leaves me in excel with the grey background.. so pretty much my application.quit doesnt seem to be working if only one workbook is open. Any idea on whats wrong?