Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.misc
|
|||
|
|||
VBA - Close without saving changes
The system runs several reports each night, and I have a macro that opens the
report it needs automatically, uses the data, then closes the report. Even in cases where all i've done is copy data from this report it asks me occasionally if I want to save changes. Sometimes I do make changes. Is there a way in a macro that I can set it to automatically close a file without either saving it, or prompting me? Any changes to these reports doesn't want to be saved so they can be used by other people, and I generally like the prompt on a usual basis, but its one I would rather be without while a macro is running. Anything I can put before ActiveWindow.Close Or in it, or something like that? |
#2
Posted to microsoft.public.excel.misc
|
|||
|
|||
VBA - Close without saving changes
PaulW wrote: Anything I can put before ActiveWindow.Close Or in it, or something like that? Hi PaulW ActiveWorkbook.Close 0 Regards Steve |
#3
Posted to microsoft.public.excel.misc
|
|||
|
|||
VBA - Close without saving changes
ActiveWindow.Close savechanges:=False
"PaulW" wrote: The system runs several reports each night, and I have a macro that opens the report it needs automatically, uses the data, then closes the report. Even in cases where all i've done is copy data from this report it asks me occasionally if I want to save changes. Sometimes I do make changes. Is there a way in a macro that I can set it to automatically close a file without either saving it, or prompting me? Any changes to these reports doesn't want to be saved so they can be used by other people, and I generally like the prompt on a usual basis, but its one I would rather be without while a macro is running. Anything I can put before ActiveWindow.Close Or in it, or something like that? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Why excel close all files when I just want to close one files | Excel Discussion (Misc queries) | |||
close workbook without closing excel and stop recursive function | Excel Discussion (Misc queries) | |||
Am i the first person to close and excel file, without saving chan | Excel Discussion (Misc queries) | |||
close button does not close | Excel Discussion (Misc queries) | |||
Excel shoud not close all active books when clicking close button | Excel Discussion (Misc queries) |