How to run macros as one close a excel?

S

Simon Lloyd

In the ThisWorkbook Module

Code
-------------------

Private Sub Workbook_BeforeClose(Cancel As Boolean
'MY MACR
End Su

-------------------

--
Simon Lloy

Regards,
Simon Lloyd
'The Code Cage' (http://www.thecodecage.com
 
M

Mike H

Hi,

In VB editor double click 'This Workbook' and paste this iin on the right
and enter your code.

Private Sub Workbook_BeforeClose(Cancel As Boolean)
'do things
End Sub

Mike
 
Top