By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
454,968 Members | 1,180 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 454,968 IT Pros & Developers. It's quick & easy.

D-Lookup

P: 51
I have a ton of DLookup results in by database and it works great.

However I just built a pop up form (fmswo) that I am using as a worksheet while viewing a invoice and when I click on the combo box (cbomesh) the choice comes up properly but populates the first value in the table where it is stored.

what I have:

where value is stored to be lookup up - "tblinventory"
field name to look up - "sellprice"
"cbomesh" control is - "meshtype"
combo box name = "cbomesh"

what I am using is:

=DLookUp("[SellPrice]","[tblinventory]","[meshtype] = '" & [cbomesh] & "'")

NOTE: It does not return an error but returns the "sellprice" of the product in the first record of "tblinventory"

I have tried countless combinations of solutions with no success.

Please help very frustrated with somthing that is probably very simple.

thanks
Gary
Jul 5 '09 #1
Share this Question
Share on Google+
5 Replies


ADezii
Expert 5K+
P: 8,679
@GLEberts
Kindly post the Row Source of cboMesh.
Jul 5 '09 #2

missinglinq
Expert 2.5K+
P: 3,532
@GLEberts
It sounds to me as if the your combobox is bound to the field in the table it pulls from, which it shouldn't be for this type of thing. Is a field listed in the Combobox Control Source?

Linq ;0)>
Jul 5 '09 #3

P: 51
update:
the table name is: "products" not "tblinventory"

the row source is -
SELECT [Products].[ProductID], [Products].[ProductName] FROM [Products] ORDER BY [ProductName];
Jul 5 '09 #4

P: 51
@missinglinq

the combo box is bound to table: tblswo
the field name = "meshtype" displays in the combo box (cbomeshtype)

yes the field "meshtype" is listed in the Ccombobox control source.

thanks
Gary
Jul 5 '09 #5

P: 51
I got the problem sorted out.
Thanks
Jul 8 '09 #6

Post your reply

Sign in to post your reply or Sign up for a free account.