View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.misc
Dave Peterson Dave Peterson is offline
external usenet poster
 
Posts: 35,218
Default beforeclose placement

The order isn't important--it does have to be under the ThisWorkbook module,
though.



Curt wrote:

Does the placement of the beforeclose have any bearing on operation. It has a
few times failed this is why I ask following is my placement. Does it need to
be last?
Thanks

Option Explicit
---------
Private Sub Workbook_BeforeClose(Cancel As Boolean)
ThisWorkbook.Save
End Sub
----------
Private Sub Workbook_open()
Userform1.Show
End Sub


--

Dave Peterson