Return value based on another cell

rikkyshh

New member
Local time
Today, 06:50
Joined
Jul 9, 2014
Messages
2
I have a database (small one which i designed)

I have created all the tables.

I then have a "form" called July-14 (i need to figure out how i can automatically replicate this form for new months)

Anyway, one of the cells pulls out a product name (using the lookup wizard), i then have a cost cell which i would like to populate automatically based on the product name.

The table July-14 links to a product table which has ONLY those 2 attributes in there, the name and cost.

How do i get it to pull the cost automatically.

Do i need to code? i hope not!

THANK YOU!!!!
 
You can retrieve product cost in two ways that I know. You can use DLookup expression on 'afterupdate' event to change cost of product when product name gets changed.

Or

You can add product name and product cost fields to the lookup field. Then on 'afterupdate' event on the lookup field, you can use VBA to send cost of the product as the product name changes.

Hope it works.
Dad
 
If you were using a combo box for the product names, I could give you code that would populate the cost via an on change event for code builder. Its an option if you have no other.
 

Users who are viewing this thread

Back
Top Bottom