Tracking users who open my workbook - part 2

  • Thread starter Thread starter Fred Flintstone
  • Start date Start date
F

Fred Flintstone

Sorry ... continuation of my previous e-mail.

The hidden worksheet or separate workbook to be set up for example ... so
username is in column A, date column B and time in column C.
 
Fred Flintstone hu kiteb:
Sorry ... continuation of my previous e-mail.

The hidden worksheet or separate workbook to be set up for example
... so username is in column A, date column B and time in column C.

What's to stop someone from copying the file and viewing it locally, or
viewing it without making changes? It is quite easy for a given user to
see the contents without forcing a save.
 
Fred,

Put this in the Thisworkbook's codemodule. Assumes you have a
worksheet named "User Data" in the same workbook. Otherwise, you
would need to open a second workbook for the data storage, which is
more complicated.

Private Sub Workbook_Open()
With ThisWorkbook.Worksheets("User Data")
.Range("A65536").End(xlUp)(2).Value = Application.UserName
.Range("B65536").End(xlUp)(2).Value = Date
.Range("C65536").End(xlUp)(2).Value = Time
End With

End Sub

HTH,
Bernie
MS Excel MVP
 
Back
Top