How simply get system's username in Access's aplication?

K

kwinto

How simply get system's username in Access's aplication?
At now I starting batch file " echo %username% > username.txt"
next I'm exporting username to table in database,
I'm thinking that exist better way.
 
D

Douglas J. Steele

Copy everything in the shaded area between Code Start and Code End and paste
it into a new module (not a class module, nor a module associated with a
form or report). When you save the module, make sure you do not name it the
same as any subs or functions in that module (or in any other module).

Once you've done that, a call to fOSUserName() will return the curent
username.
 

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