DLookup #Error

Local time
Today, 13:17
Joined
Jul 29, 2005
Messages
62
Hi all

Am currently having trouble with a DLookup function as follows

Table
======

Products
ProductID
Description
Nett

I have a form (Purchase Order Detail Subform) where by I want to enter the Product ID manually and then for the Description and Nett fields to populate automatically
I've started on the description field:
=DLookUp("[Description]","Products","[ProductID] =" & [Forms]![Purchase Order Detail Subform]![ProductID])
but this isn't right, being a bit of a newbie to access its probably because I've done something really silly...
any idea?
Thanks
 
I use DLookUp myself, but sparingly, because it can be slow. So, let me shoot from the hip with a couple of suggestions. In the table, change the txtbox to a combo, in the lookUp tab, for the ProductID. set the Row Source for the Products table. Next in the form change the txtbox to a combo box. If the controls in your form/subform are bound then you won't have to use DLookUp. You can just select from the combo box's pull-down. I hope I am being clear enough here. hth.
 
Thanks for the quick response

The problem I have tho is ProductID will have about 10,000 records, so this field needs to be a text field that I can key :confused:
 

Users who are viewing this thread

Back
Top Bottom