Change the False to True on the Saved line. This tells Excel that there have
been no changes since the last save so that it will not prompt the user to
save again.
ActiveWorkbook.Saved = True
--
HTH...
Jim Thomlinson
"Brian Matlack" wrote:
Hi!
I have two workbooks open in the same application. I want to close one
without saving it. I use this code but it still asks me if I want to
save changes.
<Code start
ActiveWindow.ActivateNext
ActiveWorkbook.Saved = False
ActiveWorkbook.Close
<End Code
Can I use code that will close without saving and not ask if I want to
save changes?
Thanks!!
--
Brian Matlack
------------------------------------------------------------------------
Brian Matlack's Profile: http://www.excelforum.com/member.php...fo&userid=3508
View this thread: http://www.excelforum.com/showthread...hreadid=510128