LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 18
Default How to ensure a VBA sub is run before closing a workbook

What syntax would I use to make sure specific subs are run before Excel
closes the active workbook. These subs are error checks and I need VBA to
vet the data and alert the user there are errors before the workbook is
closed. Is it the Workbook_Before Close event?. I tried adding the syntax
below but it didn't trigger the subs. Also would an On Save type event (if
there is one) be a better alternative. Can anyone recommend a solution with
some code please.
Many thanks
Jacqui

Private Sub Workbook_BeforeClose()

Qualifiers_Check
Disable_Check

End Sub
 
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
How to ensure workbook is saved before exiting Excel? Kathy Love Excel Discussion (Misc queries) 6 December 9th 09 09:18 PM
When opening a workbook, need to ensure user opens in a certain ce Gover Excel Discussion (Misc queries) 4 April 11th 07 03:06 PM
Closing Hidden Workbook when Active Workbook is Closed SusanK521 Excel Programming 5 September 24th 05 12:27 AM
How to ensure function does not refer to cells outside of workbook? richardbok[_2_] Excel Programming 1 February 29th 04 08:56 PM
closing excel after closing a workbook CWalsh[_2_] Excel Programming 3 January 21st 04 03:33 PM


All times are GMT +1. The time now is 10:58 PM.

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

About Us

"It's about Microsoft Excel"