Track the Username when a record is changed HELP!!

G

Guest

On the before update event procedure of the form I have written the following:

Private Sub Form_BeforeUpdate(Cancel As Integer)
Me.[EditDateTime] = Now()
Me.[Edit_USERID] = CurrentUser()

End Sub

The problem is the USERNAME is ALWAYS "Admin", this occurs on my PC at home
and on the network and it is driving me CRAZY!!

The Options in Access are correct and have my name as the User Name.

Can someone please help me out here??
 
G

G. Vaught

Admin is the default for Access if no user level security has been set.
Until you set this then you won't be able to do what you want.
 
A

Arvin Meyer [MVP]

Perhaps you would do better by grabbing and using the Windows username:

http://www.mvps.org/access/api/api0008.htm
--
Arvin Meyer, MCP, MVP
Microsoft Access
Free Access downloads
http://www.datastrat.com
http://www.mvps.org/access

ScubaDee said:
Private Sub Form_BeforeUpdate(Cancel As Integer)
Me.[EditDateTime] = Now()
Me.[Edit_USERID] = CurrentUser()

End Sub

The problem is the USERNAME is ALWAYS "Admin", this occurs on my PC at home
and on the network and it is driving me CRAZY!!

The Options in Access are correct and have my name as the User Name.

Can someone please help me out here??
 

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