P
polparrot via AccessMonster.com
I have a database that has forms set as follows:
the main form is ORDER ENTRY
this form has 2 subforms: ORDERS and COMPARABLE ITEMS
the ORDERS subform has a subform ORDER DETAILS
the ORDER DETAILS subform lists the item# of each item purchased
the COMPARABLE ITEMS subforms is linked to the ORDER DETAILS subform via a
textbox on the ORDER ENTRY form named WUC.
This is what I want to happen:
When an item# is entered, one of the fields shows that we are out of that
product. I want the COMPARABLE ITEMS subform to give me a list of items from
the qryCOMPARABLEITEMS where the WHS UNIT COST is +/- $2.00 of the WHS UNIT
COST from the ORDER DETAILS subform. This value is passed to the main form
ORDER ENTRY to the textbox mentioned above which is WUC.
The qryCOMPARABLEITEMS has the criteria on field WHS UNIT COST set to:
Between [Forms]![ORDER ENTRY]![WUC]-2 And [Forms]![ORDER ENTRY]![WUC]+2
What is happening is that the COMPARABLEITEMS subform only lists those items
that the WHS UNIT COST is exactly the same as the WUC passed from the ORDER
ENTRY from.
If I run the qryCOMPARABLEITEMS by itself (not through the ORDER ENTRY form)
it asks for the WUC and it works correctly.
Please help someone. This is driving me crazy.
Polly
the main form is ORDER ENTRY
this form has 2 subforms: ORDERS and COMPARABLE ITEMS
the ORDERS subform has a subform ORDER DETAILS
the ORDER DETAILS subform lists the item# of each item purchased
the COMPARABLE ITEMS subforms is linked to the ORDER DETAILS subform via a
textbox on the ORDER ENTRY form named WUC.
This is what I want to happen:
When an item# is entered, one of the fields shows that we are out of that
product. I want the COMPARABLE ITEMS subform to give me a list of items from
the qryCOMPARABLEITEMS where the WHS UNIT COST is +/- $2.00 of the WHS UNIT
COST from the ORDER DETAILS subform. This value is passed to the main form
ORDER ENTRY to the textbox mentioned above which is WUC.
The qryCOMPARABLEITEMS has the criteria on field WHS UNIT COST set to:
Between [Forms]![ORDER ENTRY]![WUC]-2 And [Forms]![ORDER ENTRY]![WUC]+2
What is happening is that the COMPARABLEITEMS subform only lists those items
that the WHS UNIT COST is exactly the same as the WUC passed from the ORDER
ENTRY from.
If I run the qryCOMPARABLEITEMS by itself (not through the ORDER ENTRY form)
it asks for the WUC and it works correctly.
Please help someone. This is driving me crazy.
Polly