View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Dick Kusleika[_3_] Dick Kusleika[_3_] is offline
external usenet poster
 
Posts: 599
Default ActivityLog - UserStatus

Gabriel

Kind of. You can use the Workbook_BeforeClose event to run a macro when the
user closes the workbook. However, if the user cancels the close, it may
record that in your log.

Private Sub Workbook_BeforeClose(Cancel As Boolean)

Me.Sheets("uLog").Range("A65536").End(xlUp).Offset (1, 0).Value = Now

End Sub

--
Dick Kusleika
MVP - Excel
www.dicks-clicks.com
Post all replies to the newsgroup.

"Gabriel Matache" wrote in message
...
Hi,

I've tested the code. It really works !!!
I have one more question: would it be possible to make it record the
time when the person closes the workbook ?

Thank you
Gabriel


*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!