Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Is this an Excel workbook event triggered AFTER saving

I need to get the new name of a workbook immediately after the workbook is saved. Is there an event that is triggered AFTER a save is performed i.e. I need an event like Workbook_AfterSave. I guess I can set a flag in the Workbook_BeforeSave event and then whenever the workbook/worksheet/ etc is clicked check this flag is if set record the workbook name. Any better ideas?


Thanks

Lee
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,236
Default Is this an Excel workbook event triggered AFTER saving

Lee,

You could use the BeforeSave event and handle the whole saving process in
your code. Then you'll know the name of the file by the end of the
procedure.

Rob


"Lee Drage" wrote in message
...
I need to get the new name of a workbook immediately after the workbook is

saved. Is there an event that is triggered AFTER a save is performed i.e. I
need an event like Workbook_AfterSave. I guess I can set a flag in the
Workbook_BeforeSave event and then whenever the workbook/worksheet/ etc is
clicked check this flag is if set record the workbook name. Any better
ideas?


Thanks

Lee



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 66
Default Is this an Excel workbook event triggered AFTER saving

"Lee Drage" wrote...
I need to get the new name of a workbook immediately after the workbook
is saved. . . .


Why do you believe you need this? The workbook's Name and FullName
properties are set after the Excel finishes saving the workbook, so any
other macro could access those properties.


  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Is this an Excel workbook event triggered AFTER saving

HI Thanks for the reponses.

Thanks, Rob - I had the same idea about handling all the saving myself in the BeforeSave event last night on the train!

Harlan - I store the excel workbook name because I need to refer to worksheets and custom toolbars in this workbook even when the user has moved into another workbook. I prefer not to use a variable pointing to the required worksheet because any untrapped error will result in that variable being reset to NULL, so I save the workbook name in a windows INI file. When the user changes the workbook name by SavingAs, I update the INI file. I know the workbook name is changed by Excel straight after the save but I need to a trigger to save this new workbook name to the INI file.
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Combobox Click event triggered when copying worksheet Tom Ogilvy Excel Programming 2 June 30th 05 04:54 PM
Macro triggered by an event AussieAVguy Excel Discussion (Misc queries) 2 June 16th 05 05:51 AM
Create event triggered by Pivot Chart field button Mike Collard Excel Programming 0 January 28th 04 12:00 PM
Help - Change Event triggered on File Save As Dee Veloper Excel Programming 4 October 29th 03 02:16 AM
Event triggered by Hiding/Unhiding columns? Jerry W. Lewis Excel Programming 1 July 23rd 03 09:17 AM


All times are GMT +1. The time now is 01:31 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"