Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Tracking users who opened database 2

Status
Not open for further replies.

rss01

Technical User
Oct 10, 2001
125
0
0
US
I have a database on the network that remote users open through the metaframe. It opens to a switchboard and runs an
AUTOEXEC macro that maximizes the window and runs an append query that appends a record in the USER table for the user (CurrentUser()) and the DATE_TIME (Now()). My problem is all my users show up as ADMIN. How do I get the users logon name instead of ADMIN.

Any help would be greatly appreciated.
 
You need to implement security for the db. IF you are using a secure network, there are API's to retrieve the network user name instead of the Ms. A. security.

MichaelRed
m.red@att.net

There is never time to do it right but there is always time to do it over
 
If you have a custom login screen you could just use a global variable like gstrUserName and set the name of the user to this variable long enough to put it where you want it then empty it?
 
Code:
CurrentUser()
gives you the username that the user logged into the database with. Apparently, all your users are logging in under the default username "Admin". Instead of
Code:
CurrentUser()
, use
Code:
environ("username")
. This will give you the user's network logon username instead. Hope this helps. :)
 
I apologize about not replying sooner. I appreciate the post. I'm experimenting with the environ("username")answer and also FAQ181-93 that Terry Broadbent pointed me to.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top