G
Guest
As you can probably guess, I am new to all this stuff so please bear with me. What I've got is a text box on a form and I have set its record source set to the following:
=DLookUp([QTYONHAND],"[PARTS]","[PARTNUMBER] = Forms![PARTSUSED1]")
where QTYONHAND is a number field, PARTS is my table containing the field QTYONHAND and PARTNUMBER is the other field on my PARTS form. PARTSUSED1 is the field on my current form and the data type is the same as PARTNUMBER in my table, they are Text Boxes. What I am trying to do is retrieve the QTYONHAND value from my PARTS table when the PARTSUSED1 value equals the PARTNUMBER value. What I get is the following in the text box where I want the value:
#Name?
If I attempt to adjust anything in the above function while my form is still open I get the following error:
The following doesn't contain the Automation object 'QTYONHAND'
Can someone please help? Thanks
=DLookUp([QTYONHAND],"[PARTS]","[PARTNUMBER] = Forms![PARTSUSED1]")
where QTYONHAND is a number field, PARTS is my table containing the field QTYONHAND and PARTNUMBER is the other field on my PARTS form. PARTSUSED1 is the field on my current form and the data type is the same as PARTNUMBER in my table, they are Text Boxes. What I am trying to do is retrieve the QTYONHAND value from my PARTS table when the PARTSUSED1 value equals the PARTNUMBER value. What I get is the following in the text box where I want the value:
#Name?
If I attempt to adjust anything in the above function while my form is still open I get the following error:
The following doesn't contain the Automation object 'QTYONHAND'
Can someone please help? Thanks