inventory criteria

  • Thread starter ai_enjoi via AccessMonster.com
  • Start date
A

ai_enjoi via AccessMonster.com

What criteria should be placed on the textbox "qty" on Form1 so that the
quantity that is going to be purchased should not exceed the quantity on hand,

which is shown on the textbox "unitsleft". Also if the quantity purchased
exceeds the quantity on hand, what should i do so that the quantity purchased
will equal the quantity on hand so that it will just purchase the remaining
units instead of exceeding the quantity on hand. Is this possible? If so,pls
help! Thanks!

Pls reply ASAP! Really needed! Thanks again!
 
G

George

Dear friend,

For your first question you can use a validation rule, e.g. <=[unitsleft]

About your second question: Use the after update and type the following:

if me.qty > unitsleft then
me.qty = unitleft
Endif

Hope this helps,

GeorgeCY


Ο χÏήστης "ai_enjoi via AccessMonster.com" έγγÏαψε:
 
A

Andy Hull

Hi

Go to the properties of the text box qty and choose the Data tab.

Put the following in the Validation Rule

< unitsleft

and the following in Validation Text

"The Quantityto be Purchased must be less than the Quantity on Hand"
(or whatever you want the message to be)

If this works ok do you need to also check the quantity purchased?

Regards

Andy Hull
 
A

ai_enjoi via AccessMonster.com

I have a running balance on the quantity on hand and i just wanted to make
sure that whoever uses this db won't make a mistake in inputting the quantity
to be purchased so that it won't exceed the quantity on hand. Thanks for the
help!

Andy said:
Hi

Go to the properties of the text box qty and choose the Data tab.

Put the following in the Validation Rule

< unitsleft

and the following in Validation Text

"The Quantityto be Purchased must be less than the Quantity on Hand"
(or whatever you want the message to be)

If this works ok do you need to also check the quantity purchased?

Regards

Andy Hull
What criteria should be placed on the textbox "qty" on Form1 so that the
quantity that is going to be purchased should not exceed the quantity on hand,
[quoted text clipped - 6 lines]
Pls reply ASAP! Really needed! Thanks again!
 
A

ai_enjoi via AccessMonster.com

Thanks!
Dear friend,

For your first question you can use a validation rule, e.g. <=[unitsleft]

About your second question: Use the after update and type the following:

if me.qty > unitsleft then
me.qty = unitleft
Endif

Hope this helps,

GeorgeCY

Ο χÏήστης "ai_enjoi via AccessMonster.com" έγγÏαψε:
What criteria should be placed on the textbox "qty" on Form1 so that the
quantity that is going to be purchased should not exceed the quantity on hand,
[quoted text clipped - 6 lines]
Pls reply ASAP! Really needed! Thanks again!
 
Top