Obtaining Windows Username

K

Kosio

Hello,

I am wondering if there is a way in VBA to obtain the username of
the person logged into the actual computer (not the database) or if
there is some way I can let Access know who is logged into that
particular computer.

Basically I want to set up some "security" without using the
user-level security mechanism (it conflicts with things when I need to
import data from another program). What I would like to do is create
different switchboards and based on the user name, start that user with
a different switchboard. This way I can verify that the person logged
into the computer is a certain user.

I do not need to prevent people from by-passing the switchboards and
gaining access to the tables; the reason I am setting up this
"security" is so that the people using the database are directed
towards the forms that they will be using most often. I have numerous
forms that you may navigate towards on the current switchboard, and I
would like to make switchboards for each type of user only navigate to
certain forms, so that they do not have to sift through all the other
forms that they never use. I would like to be able to make this
decision based on who is logged into the Windows machine, so that they
do not have to click on a certain level of access to make certain forms
available to them.

To sum up everything, I want to know how to obtain the username the
person used to logon to their computer (not to access, but the
computer).

Thanks,
Aaron
 

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