Add new object to a form

J

JTH

I designed a database for taking customer orders that will create a packing
slip. I now want to add the price of the item to the packing slip. I have
added the price to my “products table†and my “orders detailed†table, which
are related one to many. Now I go to my “Order sub form†in design view and
drag the price object from the “orders detailed†table list to the “Order sub
form†and save the form. When I now go to the “Order form†that contains the
“Order sub form†and select a product in the sub form the price object is
blank. What am I forgetting?
 
A

Allen Browne

You will need to lookup the current price (from the products table) and
assign it to the actual price for the invoice.

1. Open the Northwind sample database that installs with access.

2. Open the Orders Subform in design view.

3. Right-click the ProductID combo, and choose Properties.

4. Click the Build button (...) beside the AfterUpdate property.

5. Access shows you the code to use to DLookup() the price and assign it to
your text box.
 

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