Forms, subforms, and totals

K

Kit

I've done a simple database. I have a table with caterers which has a
primary key for their vendor number, a text fields for the vendor name,
phone, and expected delivery time for food (eg., 4 - 6 pm).

I have another table called food which has a field called vendor number to
match it with the vendor, and then number fields for quantity and item price,
and a text field for the item (eg., 10 orders of Pad Thai at $6.95 / each).

I have a query which calculates the to price, quantity * line item price.
The query table has vendor number, quantity, line item (text of what was
ordered), price, and total.

I also have a 2nd query which has the vendor number and the total of line
item prices (eg., if we ordered 10 pies at $10, and 5 burgers at $5, the
total fro that vendor would be $125).

So here's where I'm having trouble. I used the wizard to make a form. The
main form has the vendor, phone, and expected delivery time, and the subform
has the line item quantity, item, and price. I also want the form to put the
total order for that vendor and I can't get it to do it.

Although I put a field in the layout which references the query with the
grand totals, when I look at it, the field says #Name? I used the builder,
so it's not that I mistyped the field name.

I probably put the field in the wrong section of the form, or perhaps have
set this up in not the best way.

Any suggestions? Thanks!
 
Top