Updating a field when an option is selected

AmyLynnHill

Registered User.
Local time
Today, 09:23
Joined
Dec 7, 2005
Messages
81
I have a database with a field named "results" with 3 options of closed, open or pending. I also have a field name "closed reasons" which are toggle buttons with 5 options. I want to be able to update the "results" field to closed when one of the closed options is selected. Also, if the results is changed to "open" it deselects the closed reasons.
 
Assuming you have your toggles are in a group then add an On Click event to the group with the following code (assuming the group is called ClosedReasonGroup):

Code:
If Me.ClosedReasonsGroup > 0 Then
    Me.results = "Closed"
End If

Add an After Update event event to the Results field with the following code:
Code:
If Me.results = "Open" Then
    Me.ClosedReasonsGroup = 0
End If

hth
Chris
 

Users who are viewing this thread

Back
Top Bottom