Hi Chris,
Thank you for your advice.
My FE is connected to SQLServer 2005 back end. I modify my table to add a
column 'Owner' and assigh SUSER_SNAME() as default value. I found that
SUSER_SNAME() return Domain\Username which does not match value provided by
fOSUserName() which return only username.
How to store only username in the Owner column?
SF
"Chris O'C via AccessMonster.com" <u29189@uwe> wrote in message
news:8799efd28c263@uwe...
> The code here will get the user's windows name:
>
> http://www.mvps.org/access/api/api0008.htm
>
> But you can't prevent users from browsing what's in the tables unless you
> add
> security features. Put the data in SQL Server tables, where you can
> administer security. The express version is free.
>
> Chris
> Microsoft MVP
>
>
> SF wrote:
>>Hi,
>>
>>I was assign to develop an Admin Forms database for my office. It consists
>>of 20 or more form. Our HR personel adviced us not to allow browsing staff
>>information. Is there a way to capture login name of the current user from
>>AD? I want to bing this login name to the name of staff sothat staff who
>>uses the form can only select their own name (I want to restirct this
>>because if user can browse other staff name he/she can see the remaining
>>balance of the medical allowance, education of the other.).
>>
>>TIA
>>
>>SF
>
> --
> Message posted via http://www.accessmonster.com
>