Checkbox command

G

Guest

Hello,

I am creating a form for rental orders. The form would be based on a
customers table, an orders table, and an inventory table, all with related
id.

Since the items are for rent, the inventory table has an Available checkbox
that indicates if the item is currently available (not rented).
I then have a query, which limits the items to only those items where the
Availabe checkbox is checked.

In the form I have a Item list box based on this query.
Next to this list box there is a Returned checkbox to be checked when the
item is returned.

I would like to see if there is a way so that when the Returned checkbox (in
the orders form) is checked, the Available checkbox for the corresponding
item in the Inventory table/query is also checked. But, I would also want it
so that when a new order is placed and the item is selected from the Item
list (in the orders form) without the Returned checkbox checked, then the
Available checkbox for the corresponding item in the Inventory table/query is
also unchecked (and therefore does not even show up in the query or Item list
box [for the next order].

I appreciated you assistance.

Thank you.
 
J

JohnFol

Sounds like whn the ReturnedCheckbox is clicked, you actually need to do an
update on the inventory table to set the available flag to True, and then
requery the list box.
 
G

Guest

Yes, that's right. I think the part about unclicking it when a new order
comes in and that item is selected (becoming unavailable) that is the tricky
part...

JohnFol said:
Sounds like whn the ReturnedCheckbox is clicked, you actually need to do an
update on the inventory table to set the available flag to True, and then
requery the list box.


hsdaguilar said:
Hello,

I am creating a form for rental orders. The form would be based on a
customers table, an orders table, and an inventory table, all with related
id.

Since the items are for rent, the inventory table has an Available
checkbox
that indicates if the item is currently available (not rented).
I then have a query, which limits the items to only those items where the
Availabe checkbox is checked.

In the form I have a Item list box based on this query.
Next to this list box there is a Returned checkbox to be checked when the
item is returned.

I would like to see if there is a way so that when the Returned checkbox
(in
the orders form) is checked, the Available checkbox for the corresponding
item in the Inventory table/query is also checked. But, I would also want
it
so that when a new order is placed and the item is selected from the Item
list (in the orders form) without the Returned checkbox checked, then the
Available checkbox for the corresponding item in the Inventory table/query
is
also unchecked (and therefore does not even show up in the query or Item
list
box [for the next order].

I appreciated you assistance.

Thank you.
 

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