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

Retreive Network ID into access database

Status
Not open for further replies.

snowyowl

Programmer
Dec 16, 2002
16
GB
Hi.
I'm thinking of putting the users network id into a database so it can be used as a basic piece of information.

Does anybody know how to pick up the current Network ID and place it in an access database. This would then be used as a default user when retreiving records from tables etc.

Otherwise, would it be better to show a form when the database is started up that asks the user to select who they are and then keep the form open which can then be used to select their details in the database.

Any experiences or pitfalls would be welcome

Thanks
 
If you are using Access security, you can take advantage of the CurrentUser to determine this. When a user logs into a db that is enabled with Access Security, the username they enter is stored into a public variable called CurrentUser you can use for this purpose. There is code out there for grabbing the "network" id and you could use this, but I have not used it myself. Reason: If one user is logged into the machine, but several persons use it, how do you know which one it really is. Example: a call center type situation or training area, where the machine is logged into a sort of pulic id, then each user logs into the appropriate apps they have permission for. -------------------------------------
Only two things are infinite, the
universe and human stupidity, and
I'm not sure about the former.
(Albert Einstein)

Robert L. Johnson III
MCSA, CNA, MCP, Network+, A+
w: robert.l.johnson.iii@citigroup.com
h: mstrmage@tampabay.rr.com
 
On NT Network Environ("UserName")
On Novell Network Environ("NWUserName")

Craig
 
Yes thanks for that. Of course if the user selects who they are in a form the next user to go in to that form will overwrite what the previous user had!

Good thinking batman!
All I need to do now is learn VB !

Thanks again much appreciated
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top