Form Problem

N

Nancy

I need some help here. I have used the MS Office Template “Orders
Management†and made some minor changes to the tables. I am having some
problems with my calculation fields. My order subtotal box gets the
following error msg: “#Name?â€. In my order total box I get the following:
“#Errorâ€. Also, My Orders Summary comes up with a error and I believe this
is the root of the problem but can’t seem to figure it out. When I click on
the Orders Summary I get the Enter Parameter Value box and has “Order Details
Totals.OrderID and then the blank box. If I just hit O.K. it brings up the
Query Table view. When I try to switch to Design View it says the
following: MS Access can’t represent the join expression [Order Details
Totals].OrderID=Orders.OrderID in design view.

My tables are as follows:

Order Details: Order Detail ID
Order ID
Nomenclature ID
Part Number
Quantity
Unit Price

Orders: Order ID
Customer ID
Employee ID
Order Date
PO Number
Ship Date
Shipping Method
Taxes
Comments

My Queries:

Order Details Extended: Order Detail ID
Order ID
Nomenclature ID
Part Number
Quantity
Unit Price
Subtotal
In Design view I have the following:
Subtotal: CCur(Nz([Quantity]*[Unit Price]))

Order Details Totals: Order ID
Line Item Totals
In Design View I have the following:
Line Item Totals: Subtotal and then the Sum Command


Orders Summary Order ID
Line Item Totals
Order Totals
Customer ID
Employee ID
Order Date
PO Number
Ship Date
Shipping Method ID
Comments
This is the code behind the Orders Summary:

SELECT Orders.OrderID, [Order Details Totals].[Line Item Totals], Nz([Line
Item Totals])+Nz([Taxes]) AS [Order Totals], Orders.CustomerID,
Orders.EmployeeID, Orders.OrderDate, Orders.PurchaseOrderNumber,
Orders.ShipDate, Orders.ShippingMethodID, Orders.Comment
FROM [Order Details Totals] INNER JOIN Orders ON [Order Details
Totals].OrderID=Orders.OrderID;
Forms:
Main Form has the Orders Table as the Record Source
Subform has the Order Detail Subform as the Record Source

The Order Details Subform has the following: Nomenclature
Part Number Quantity
Unit Price.
In the footer of my subform I have the following: =Nz(Sum([Subtotal]),0)

I want to add calculations to the bottom of the form to add the order
totals, tax, etc. In this order subtotal box I have the following:
=[Order Details Subform].[Form]![txtOrderDetailsTotal]

In the order total box I have the following:
=[txtOrderSubtotal]+Nz([FreightCharge])+Nz([Taxes])

I would appreciate any help you can give me. I am fairly new to Access and
just trying to get this to work for me. Also I am using MS Access 2007.
Thanks
 
R

rquintal

 When I try to switch to Design View  it says the
following: MS Access can’t represent the join expression [Order Details
Totals].OrderID=Orders.OrderID in design view.  

My tables are as follows:

Order Details:                          Order Detail ID
Order ID

Orders:                         Order ID

My Queries:    

Order Details Extended: Order Detail ID
Order ID
Nomenclature ID
Part Number
Quantity
Unit Price
Subtotal
                In Design view I have the following:
        Subtotal: CCur(Nz([Quantity]*[Unit Price]))

Order Details Totals:           Order ID
Line Item Totals
                                In Design View I have the following:
Line Item Totals: Subtotal and then the Sum Command

Orders Summary          Order ID
SELECT Orders.OrderID, [Order Details Totals].[Line Item Totals], Nz([Line

I would appreciate any help you can give me.  I am fairly new to Access and
just trying  to get this to work for me.  Also I am using MS Access 2007.  
Thanks

You have Oder ID and OrderID references. Pick one and change all of
the other ones to the one you picked.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top