Guest_imported
New member
- Jan 1, 1970
- 0
Hello, Im trying to use the dlookup function in a query. have got it working good when there is only one criteria eg, Supplier Part Name: DLookUp("[fldSupplierPartName]","tblSupplierParts","fldProductID =" & [tblOrdersAndQuantitys]![fldProductID])
Works fine
However i want the lookup to take into account another critera in tblSupplierParts. I want dlookup to lookup
the value from a textbox in a form as an And condition. i have tried using the following method.
Supplier Part Name: DLookUp("[fldSupplierPartName]","tblSupplierParts","fldProductID =" & [tblOrdersAndQuantitys]![fldProductID] And "fldSupplierID=" & [Forms]![frmPartOrder]![fldSupplierID])With this code it isn't producting the correct output. im just wondering if the way i have added this extra criteria appears correct.
Any suggestions greatly appreciated, Thanks.
Works fine
However i want the lookup to take into account another critera in tblSupplierParts. I want dlookup to lookup
the value from a textbox in a form as an And condition. i have tried using the following method.
Supplier Part Name: DLookUp("[fldSupplierPartName]","tblSupplierParts","fldProductID =" & [tblOrdersAndQuantitys]![fldProductID] And "fldSupplierID=" & [Forms]![frmPartOrder]![fldSupplierID])With this code it isn't producting the correct output. im just wondering if the way i have added this extra criteria appears correct.
Any suggestions greatly appreciated, Thanks.