In the Control Source of ApplicantName type:
If the AppID is numeric
=dlookup("[AppName]", "App", "[AppID] = " & me.App_Idlbl )
If the AppID is text
=dlookup("[AppName]", "App", "[AppID] = ' " & me.App_Idlbl & " ' " )
I'm a little confused ... I thought field name was AppID. Why is it called App_Idlbl on your form? That sounds like a label, not a
text box.
You might want to read about DLookUp. The syntax is
=dlookup("[FieldValueYouWantToReturn]", "TableName", "[FieldInTheTable] = " & me.FieldOnFormThatMatchesFieldInTheTable
HTH,
Debbie
|I tried your suggestion. I got #Name? in the textbox. I tried several
| different variations of your suggestion but couldn't get it to work. Just
| for info, the first textbox is named "App_Idlbl", the second is named
| "ApplicantName" I dont know if this matters.. Any other
| suggestions...Thanks
| | > Kerman,
| >
| > I think you could use something like this:
| >
| > In the Control Source of your second text box type:
| >
| > If the AppID is numeric
| > =dlookup("[AppName]", "App", "[AppID] = " & me.AppID )
| >
| > If the AppID is text
| > =dlookup("[AppName]", "App", "[AppID] = ' " & me.AppID & " ' " )
| >
| > HTH,
| > Debbie
| >
| >
| > | > |I have two textboxes on my form. I want to enter an account number
| [AppID]
| > | into the first box, I then want the second box to automatically display
| > the
| > | company name [AppName] associated with the account number. I only want
| > the
| > | [AppID] inserted into my "Account" table. The table with the [AppId]
| and
| > | [AppName] is "App" Thanks for any help...Randy
| > |
| > |
| >
| >
|
|