![]() |
VBA Save
Hi
I used the ffg code, Private Sub cmdReturn_Click() ActiveWindow.Close([savechanges]) = False End Sub but it returns an error ...... "Compile Error....................Assignment to constant not permitted" is there a different code i can use to not save a doc or just not get excel to ask for save? Regards |
VBA Save
How about:
Private Sub cmdReturn_Click() ActiveWorkbook.Close savechanges:=False End Sub Zaahir wrote: Hi I used the ffg code, Private Sub cmdReturn_Click() ActiveWindow.Close([savechanges]) = False End Sub but it returns an error ...... "Compile Error....................Assignment to constant not permitted" is there a different code i can use to not save a doc or just not get excel to ask for save? Regards -- Dave Peterson |
VBA Save
Thanx david, works beautifuly
"Zaahir" wrote: Hi I used the ffg code, Private Sub cmdReturn_Click() ActiveWindow.Close([savechanges]) = False End Sub but it returns an error ...... "Compile Error....................Assignment to constant not permitted" is there a different code i can use to not save a doc or just not get excel to ask for save? Regards |
All times are GMT +1. The time now is 06:09 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com