![]() |
Close Workbook
I have this code and I want to add a close command to it Code: -------------------- Workbooks.Open "c:\SS1.xls" -------------------- this code is attached to to a autoshape on the active workbook. I want the active workbook to close after the new workbook opens. -- oberon.black ------------------------------------------------------------------------ oberon.black's Profile: http://www.excelforum.com/member.php...o&userid=26732 View this thread: http://www.excelforum.com/showthread...hreadid=469392 |
Close Workbook
Hi Oberon,
Assuming that the code resides in the workbook holding the shape code, try: Workbooks.Open "c:\SS1.xls ThisWorkbook.Close SaveChanges:= True Change True to False if you do not want changes saved. --- Regards, Norman "oberon.black" wrote in message news:oberon.black.1vouye_1127271909.8415@excelforu m-nospam.com... I have this code and I want to add a close command to it Code: -------------------- Workbooks.Open "c:\SS1.xls" -------------------- this code is attached to to a autoshape on the active workbook. I want the active workbook to close after the new workbook opens. -- oberon.black ------------------------------------------------------------------------ oberon.black's Profile: http://www.excelforum.com/member.php...o&userid=26732 View this thread: http://www.excelforum.com/showthread...hreadid=469392 |
All times are GMT +1. The time now is 01:11 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com