Hi, I have a Loans form and an Equipment table.
I would like the 'Available' checkbox in the Equipment table to be unchecked when when the user clicks the 'Submit' button on the Loans form (i.e. when an item is loaned out) - but I only want the checkbox corresponding to the item (Equipment ID) that has been selected to change.
I have tried this:
Private Sub Submit_Click()
CurrentDb.Execute "Update Equipment Set Available = 0 Where Loans.Equipment ID = Equipment.Equipment ID"
End Sub
but it doesn't work
I am very new to VB so apologies if the above is just silly coding!
Thanks in advance for any advice!
Rachael
I would like the 'Available' checkbox in the Equipment table to be unchecked when when the user clicks the 'Submit' button on the Loans form (i.e. when an item is loaned out) - but I only want the checkbox corresponding to the item (Equipment ID) that has been selected to change.
I have tried this:
Private Sub Submit_Click()
CurrentDb.Execute "Update Equipment Set Available = 0 Where Loans.Equipment ID = Equipment.Equipment ID"
End Sub
but it doesn't work

I am very new to VB so apologies if the above is just silly coding!
Thanks in advance for any advice!
Rachael