event failing

G

Guest

Have the following code works most of the time. On occasion will not trigger
and asks if you want to save changes. Do not understand why this occionsial
failure.
Thanks for looking
Heres code
Private Sub Workbook_BeforeClose(cancel As Boolean)
'Call catsheetdel
UserForm3.Show False
Call catsheetdel
DoEvents
UserForm3.Hide
ThisWorkbook.Save
End Sub
 
G

Guest

Generally this is because you have disabled events (whether you meant to or
not). Events are enabled at the application level, so if they have been
disabled, they are disabled for the whole Excel application.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top