Hi Doug
If Application.Workbooks.Count = 1 Then
' only me
Else
' others
End If
Remember to deal with potential "save changes ?" requests.
HTH. Best wishes Harald
"Chaplain Doug" skrev i melding
...
Excel 2003. I have placed a button on my workbook's "switchboard" and
want
to do the following when the button is depressed:
1. If there are other workbooks opened, then just close this workbook
(Activeworkbook.Close)
2. If there are no other workbooks opened, then quit the Excel
application
(Application.Quit)
How may I test to see if there are any other workbooks opened before I
take
one of the above two actions? Thanks for the help.
--
Dr. Doug Pruiett
Good News Jail & Prison Ministry
www.goodnewsjail.org