Refresh issue with unbound form

Malcy

Registered User.
Local time
Today, 15:41
Joined
Mar 25, 2003
Messages
586
Hi
I have an unbound data entry form with a combo box to select a contact (cboApplicant). The user then enters various bits of data about the person but whereas the combo shows forename, surname and address line 1 when it is open, once you have moved on it only shows surname.
I have tried to add another set of unbound textboxes to try to get the full data on the contact as a means of verification whilst the data is being entered.
The code I have used is
Code:
=DLookUp("strConAdd1","tblContacts","[lngConId] = " & [Me].[cboApplicant] & "")
When I select the applicant from the combo box the textboxes simply say #Name?
I tried putting Me.Refresh in the after update event of the combo but it had no effect.
Is what I want possible or would I be better to base these results on bound textboxes from an underlying query?
Thanks
 
=DLookUp("strConAdd1","tblContacts","[lngConId] = " & [Me].[cboApplicant])

???
ken
 
Hmm
This is not as easy as I thought.
I tried Ken's code but it had same effect as mine (unusual since it normally works about 100 times better than mine!) and I had a look at Pat's example suggested by indesisiv but cannot quite fathom it out. I can't quite see how the selection from the combo feeds into the autolookup.
Must be time for a break to restore sugar levels!!
Will plug back in after lunch and see if the brain cells are working then.
Thanks for your help.
 

Users who are viewing this thread

Back
Top Bottom