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 bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

IS THERE AWAY TO MAKE A LOGIN TRACKING SYSTEM

Status
Not open for further replies.

chubby

Programmer
Apr 28, 2001
278
US
I'm using Windows NT 4.0 on a secured network using Access 97. The data base is password protected, each user has his or her own login and password code. Is there anyway I can track who has been in the data base. I need a running log that tracks the time users logged in and time logged out.

Thanks
 
Thanks but what's an Audit file??? Second I'm not a LAN Admin type, I don't have the access or knowlegde to do something like that. Is there any other way I can track who's used the database??
 
Chubby,

How familiar are you with programming VBA in Access? I think the best way would be to write a function that runs on open and again on close that records the user name, date, and time in a table.

This code returns the user name of the current user but I'm not sure if it will run in Access 97 as is. You may have to tweek it. I have it running in 2000. I refer to it in a function that records what changes are made to a table, when and by whom.

Function NetworkUserName() As String
'Retreive network user name
Dim lngStringLength As Long
Dim sString As String * 255

lngStringLength = Len(sString)
sString = String$(lngStringLength, 0)

If wu_GetUserName(sString, lngStringLength) Then
NetworkUserName = Left$(sString, InStr(sString, Chr(0)) - 1)
Else
NetworkUserName = "Unknown"
End If

End Function

Hope this helps.

gricks
 
I have a related question - is there a way to determine if the current user is a member of a specific group? I mean within Windows, not Access - I can see how to do this in Access, but ideally I would like be able to get a person's NT ID (which works fine) and then determine if they are a member of a specific NT group (which I don't have a clue).

Thanks for any insight
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top