av8tordude
04-24-2011, 01:51 PM
how can I self kill my workbook and close the excel application as well. I've tried this code, but it does not work.
Sub KillMe()
With ThisWorkbook
Call TitleBarOpen
.Saved = True
.ChangeFileAccess Mode:=xlReadOnly
Kill .FullName
.Close False
End With
With Application
.DisplayAlerts = False
.Quit
End With
End Sub
Sub KillMe()
With ThisWorkbook
Call TitleBarOpen
.Saved = True
.ChangeFileAccess Mode:=xlReadOnly
Kill .FullName
.Close False
End With
With Application
.DisplayAlerts = False
.Quit
End With
End Sub