![]() |
saveAS AfterUpdate
In excel if you open a workbook and change anything then you are prompted with the save work when workbook ic closed. How can i reference whether a book has been ammended or updated so that i can diplay the saveAs dialog box instead in order to create audit trail. What i really want is something along lines of if workbook has changed/updated/ammended whatever then application.dialogs.SAVEAS ETC else close end if This code will be activated from within a bigger piece of code that follows a number of criteria to decide whether to paste a new set of values in the worksheet -- cereldine ------------------------------------------------------------------------ cereldine's Profile: http://www.excelforum.com/member.php...o&userid=32069 View this thread: http://www.excelforum.com/showthread...hreadid=538044 |
saveAS AfterUpdate
check the Saved property of the workbook
if not ActiveWorkbook.Saved then fname = Application.GetSaveAsFileName() Activeworkbook.SaveAs fname end if -- Regards, Tom Ogilvy "cereldine" wrote: In excel if you open a workbook and change anything then you are prompted with the save work when workbook ic closed. How can i reference whether a book has been ammended or updated so that i can diplay the saveAs dialog box instead in order to create audit trail. What i really want is something along lines of if workbook has changed/updated/ammended whatever then application.dialogs.SAVEAS ETC else close end if This code will be activated from within a bigger piece of code that follows a number of criteria to decide whether to paste a new set of values in the worksheet -- cereldine ------------------------------------------------------------------------ cereldine's Profile: http://www.excelforum.com/member.php...o&userid=32069 View this thread: http://www.excelforum.com/showthread...hreadid=538044 |
saveAS AfterUpdate
Hi Cereldine,
thisworkbook.saved returns you information if any change (including updating links) was done in the workbook since opening/last saving it. Regards, Ivan |
All times are GMT +1. The time now is 12:35 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com