Link to home
Start Free TrialLog in
Avatar of jmcdonald69124
jmcdonald69124Flag for United States of America

asked on

Access 2003 VBA and Windows Username question

Can I use the windows username in a vba function to compare to a value in an access database and then return the security level based on that, I really only need help getting the Windows username from the system to the vba module, help I am constrained to VBA/Access 2003 only and I know that this would take about 5 minutes in C# and SQL Server. Any ideas would be appreciated.
Avatar of mbizup
mbizup
Flag of Kazakhstan image

Use the following VBA:

strUserName = environ(UserName)
ASKER CERTIFIED SOLUTION
Avatar of mbizup
mbizup
Flag of Kazakhstan image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial