Form returns #name? with environ=("user")

P

PaulM

I a form the variable environ=("user") is added the see whats the user. On some PC's it works others donnt. I don not know why. PC's have same Servicepacks etc. But I can not find the direct answer why it causes the #name? in the access form. Yes I did test it with USER and without brackets etc.
 
D

Douglas J. Steele

Getting the user ID through the environment variable isn't a particularly
good approach, as it's so trivial to change the value of an environment
variable.

Try using the code in http://www.mvps.org/access/api/api0008.htm at "The
Access Web" instead.

--
Doug Steele, Microsoft Access MVP

(No private e-mails, please)



PaulM said:
I a form the variable environ=("user") is added the see whats the user. On
some PC's it works others donnt. I don not know why. PC's have same
Servicepacks etc. But I can not find the direct answer why it causes the
#name? in the access form. Yes I did test it with USER and without brackets
etc.
 
P

PaulM

I have no idea how it works but I can have someone look at this suggestion. But, this does not solve the issue, because it worked before and on other computers as well. So where is the difference? Your suggestion might be better, but in this case I am curious why it doesn't work.

Thnx Paul
 
P

Peter

There are 2 other Environ vars that work. Auth_User and
username.

I've found them both to work on both XP and 2k.
-----Original Message-----
I have no idea how it works but I can have someone look
at this suggestion. But, this does not solve the issue,
because it worked before and on other computers as well.
So where is the difference? Your suggestion might be
better, but in this case I am curious why it doesn't work.
 

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