pinkpanther6666
Board Regular
- Joined
- Feb 13, 2008
- Messages
- 194
- Office Version
- 365
- Platform
- Windows
Please could i have some help with the Dlookup command in Access 2010, My database is partly constructed by the below
Table ........................ Player
Fields
PlayerName ...............TextBox
Gender ......................TextBox
Form Name ................Main
Fields
Name ....................... This is a combobox called Combo2
Sex ...........................This is a Text Box
In the control source of the "Sex" text box in my form i have put : -
=DLookUp("Gender","Player","[PlayerName]=" & "[Combo2]")
also i have tried
=DLookUp("Gender","Player","[PlayerName]=" & "[Name]")
What i want to happen in my form Is to select a name and there gender autofills the Sex Text Box
At the moment what appears at the moment is #Error
Can anyone help me please
Many Many Thanks in advance
Steve


Table ........................ Player
Fields
PlayerName ...............TextBox
Gender ......................TextBox
Form Name ................Main
Fields
Name ....................... This is a combobox called Combo2
Sex ...........................This is a Text Box
In the control source of the "Sex" text box in my form i have put : -
=DLookUp("Gender","Player","[PlayerName]=" & "[Combo2]")
also i have tried
=DLookUp("Gender","Player","[PlayerName]=" & "[Name]")
What i want to happen in my form Is to select a name and there gender autofills the Sex Text Box
At the moment what appears at the moment is #Error
Can anyone help me please
Many Many Thanks in advance
Steve


