abhi.karnawat
Registered User.
- Local time
- Tomorrow, 05:59
- Joined
- Dec 31, 2009
- Messages
- 12
hi,
i have 2 tables one containing stock and one containing prices.
in order to give a price to a stock item the following criteria's should match:
shape, size, color, clarity
for example:
my stock table: shape:RB, Size: 3.3mm, Color: F, Clarity: VS1, Price: 0
Price table: Size: 3.3mm, Color: F, Clarity: VS1, Price: 150$
after all these criteria's are the same the stock table should take the price 150 automatically after updating the final criteria of clarity.
i need 2 functions:
1. i need to update all the unsold stock prices at once if my price list has changed.
2. when i enter new stock in the stock table through a form it should take the price of the individual stock item automatically.
for option 2, i have tried using in my stock entry form the following code:
Clarity Afterupdate()
if shape="RB" and mm=Form_RBWPrices.mm and Col_D_Z=Form_RBWPrices.Clour and Clarity=Form_RBWPrices.Clarity then
Form_DiamondStockRegistery.GIV_Price=RBWPrices.Price
end if
end sub
----> Didnt Work
For option 1 i thought of using an update query but i have no idea.. where to start on that...and also dont know if it would be right to use an Update query.
Would appreciate the help as it would save me a lot of work time in the future.
thx
abhi
i have 2 tables one containing stock and one containing prices.
in order to give a price to a stock item the following criteria's should match:
shape, size, color, clarity
for example:
my stock table: shape:RB, Size: 3.3mm, Color: F, Clarity: VS1, Price: 0
Price table: Size: 3.3mm, Color: F, Clarity: VS1, Price: 150$
after all these criteria's are the same the stock table should take the price 150 automatically after updating the final criteria of clarity.
i need 2 functions:
1. i need to update all the unsold stock prices at once if my price list has changed.
2. when i enter new stock in the stock table through a form it should take the price of the individual stock item automatically.
for option 2, i have tried using in my stock entry form the following code:
Clarity Afterupdate()
if shape="RB" and mm=Form_RBWPrices.mm and Col_D_Z=Form_RBWPrices.Clour and Clarity=Form_RBWPrices.Clarity then
Form_DiamondStockRegistery.GIV_Price=RBWPrices.Price
end if
end sub
----> Didnt Work
For option 1 i thought of using an update query but i have no idea.. where to start on that...and also dont know if it would be right to use an Update query.
Would appreciate the help as it would save me a lot of work time in the future.
thx
abhi