A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Using Forms
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

DLookup returns same name



 
 
Thread Tools Display Modes
  #11  
Old May 24th, 2010, 04:14 PM posted to microsoft.public.access.forms
Wordwonderor
external usenet poster
 
Posts: 11
Default DLookup returns same name

I've changed to a combo box. It seems to work. But I'd like to understand why
the DLook up didn't, as that approach sem to be more direct.

The Solicitor ID is a number field in the form's record source. It is tied
to the Contacts ID.

"BruceM via AccessMonster.com" wrote:

Actually, I realize now that you did mention this, but I misunderstood the
problem. Is SolicitorID a number field? Is the Solicitor text box bound to
LName in the form's Record Source?

Wordwonderor wrote:
Thank you, but it didn't help. The Solicitor ID control is on the form and it
updates as I scroll though the Contacts. But the Solicitor's name field (the
dlookup) doesn't. It always shows the solicitor with Solicitor ID 1.

In an Access 2003 database, I have a form, Contacts, based on a Contacts
table that includes potential donors and the Solicitor ID of their assigned

[quoted text clipped - 26 lines]
This does assume that there is a control named [Soliciter ID] on the form,
which contains the desired ID.


--
Message posted via AccessMonster.com
http://www.accessmonster.com/Uwe/For...forms/201005/1

.

  #12  
Old May 24th, 2010, 04:19 PM posted to microsoft.public.access.forms
Wordwonderor
external usenet poster
 
Posts: 11
Default DLookup returns same name

I used the combo box but not sure how it works. I'd still like to know why
the DLookup which seems more direct didn't.

The forms record source is simply the Contacts table. The Solicior ID is a
number field in the Contacts Table and a autonumber in the Solicitors table.

"John W. Vinson" wrote:

On Fri, 14 May 2010 08:42:01 -0700, Wordwonderor
wrote:

Thank you, but it didn't help. The Solicitor ID control is on the form and it
updates as I scroll though the Contacts. But the Solicitor's name field (the
dlookup) doesn't. It always shows the solicitor with Solicitor ID 1.


Please post the SQL view of the form's Recordsource, and that of the combo
box's Rowsource. Also indicate the datatype of the SolicitorID.

I'd be inclined just to have a combo box bound to SolicitorID but displaying
the solicitor name, rather than having any DLookUp or separate control; is
there some reason you have chosen not to do so?
--

John W. Vinson [MVP]
.

  #13  
Old May 26th, 2010, 09:26 PM posted to microsoft.public.access.forms
John W. Vinson
external usenet poster
 
Posts: 18,261
Default DLookup returns same name

On Mon, 24 May 2010 08:19:01 -0700, Wordwonderor
wrote:

I'll be glad to try to help, but you'll need to help me do so: plsese post
your form's Recordsource, the combo box's Rowsource, and the datatype of the
solicoitor ID. I can't see them from here, and only that information will
enable me to reply.

I used the combo box but not sure how it works. I'd still like to know why
the DLookup which seems more direct didn't.

The forms record source is simply the Contacts table. The Solicior ID is a
number field in the Contacts Table and a autonumber in the Solicitors table.

"John W. Vinson" wrote:

On Fri, 14 May 2010 08:42:01 -0700, Wordwonderor
wrote:

Thank you, but it didn't help. The Solicitor ID control is on the form and it
updates as I scroll though the Contacts. But the Solicitor's name field (the
dlookup) doesn't. It always shows the solicitor with Solicitor ID 1.


Please post the SQL view of the form's Recordsource, and that of the combo
box's Rowsource. Also indicate the datatype of the SolicitorID.

I'd be inclined just to have a combo box bound to SolicitorID but displaying
the solicitor name, rather than having any DLookUp or separate control; is
there some reason you have chosen not to do so?
--

John W. Vinson [MVP]
.

--

John W. Vinson [MVP]
 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 02:40 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.