Hi,
I'm trying to get a certain field to appear only when a value from another combobox field is selected. Specifically, when "Sample Rejected" is selected in the field "PcrLabResults, " I would like the "ReasonsRejecte d" field to appear. I've set the visibility option for "ReasonsRejecte d" to "No" already. I still can't get it to work. Do I need to do anything after entering this code (ie save, click "run," etc), or will it update in the form automatically? Here's my code - please let me know what I'm doing wrong. Many thanks in advance.
PS - I've looked at these two threads, and still can't seem to get it right:
I'm trying to get a certain field to appear only when a value from another combobox field is selected. Specifically, when "Sample Rejected" is selected in the field "PcrLabResults, " I would like the "ReasonsRejecte d" field to appear. I've set the visibility option for "ReasonsRejecte d" to "No" already. I still can't get it to work. Do I need to do anything after entering this code (ie save, click "run," etc), or will it update in the form automatically? Here's my code - please let me know what I'm doing wrong. Many thanks in advance.
Code:
Private Sub PcrLabResults_AfterUpdate()
If Me.PcrLabResults = "Sample rejected" Then
RejectionReasons.Visible = True
End If
End Sub
PS - I've looked at these two threads, and still can't seem to get it right:
Comment