Hi, I'm trying to keep track of who opens an excel workbook and the date.
I have some code here to identify the user:
This is a good start but a single cell is not a good solution because I would always just see me as the last person who opened it. Is there a way to use the formula so that it will display the user in the next cell? for example, if John opens it on 01/01/19 and then Mary opens it on 01/02/19, then when I open it on 01/03/19 I should see A1 = John, B2 = 01/01/19, A2 = Mary, B2 = 01/02/19, and A3 = Me, 01/03/19. Then after about 100 rows, it deletes the audit trial and starts over at A1 so it doesn't get to big.
You could call it an Audit Trail worksheet, I think it would be a great addition to the forum.
Thank you,
I have some code here to identify the user:
Code:
Public Function UserName() UserName = Environ$("UserName")
End Function
This is a good start but a single cell is not a good solution because I would always just see me as the last person who opened it. Is there a way to use the formula so that it will display the user in the next cell? for example, if John opens it on 01/01/19 and then Mary opens it on 01/02/19, then when I open it on 01/03/19 I should see A1 = John, B2 = 01/01/19, A2 = Mary, B2 = 01/02/19, and A3 = Me, 01/03/19. Then after about 100 rows, it deletes the audit trial and starts over at A1 so it doesn't get to big.
You could call it an Audit Trail worksheet, I think it would be a great addition to the forum.
Thank you,