S
SPK
I am facing a problem after disabling the text box based on the value of
another text box.
The problem is the text boxes appear disabled or enabled based on the last
form selection of the text. I have used the following code for the same. And
when I close and open the database the disabled text boxes appear enabled
again.
Private Sub Result_AfterUpdate()
If Me.Result.Text = "Positive" Then
Me.Drug_Incub_Test_Dt.Enabled = True
Me.OD_Drug_Incub.Enabled = True
Me.OD_Without_Drug_incub.Enabled = True
Me.Cutoff_OD_Incub.Enabled = True
Me.Result_Incub.Enabled = True
Me.Neutralising_Ab_Test_Dt.Enabled = True
Me.OD_Neut.Enabled = True
Me.Cutoff_OD_Neut.Enabled = True
Me.Result_Neut.Enabled = True
Else
Me.Drug_Incub_Test_Dt.Enabled = False
Me.OD_Drug_Incub.Enabled = False
Me.OD_Without_Drug_incub.Enabled = False
Me.Cutoff_OD_Incub.Enabled = False
Me.Result_Incub.Enabled = False
Me.Neutralising_Ab_Test_Dt.Enabled = False
Me.OD_Neut.Enabled = False
Me.Cutoff_OD_Neut.Enabled = False
Me.Result_Neut.Enabled = False
End If
End Sub
can anobody help.
another text box.
The problem is the text boxes appear disabled or enabled based on the last
form selection of the text. I have used the following code for the same. And
when I close and open the database the disabled text boxes appear enabled
again.
Private Sub Result_AfterUpdate()
If Me.Result.Text = "Positive" Then
Me.Drug_Incub_Test_Dt.Enabled = True
Me.OD_Drug_Incub.Enabled = True
Me.OD_Without_Drug_incub.Enabled = True
Me.Cutoff_OD_Incub.Enabled = True
Me.Result_Incub.Enabled = True
Me.Neutralising_Ab_Test_Dt.Enabled = True
Me.OD_Neut.Enabled = True
Me.Cutoff_OD_Neut.Enabled = True
Me.Result_Neut.Enabled = True
Else
Me.Drug_Incub_Test_Dt.Enabled = False
Me.OD_Drug_Incub.Enabled = False
Me.OD_Without_Drug_incub.Enabled = False
Me.Cutoff_OD_Incub.Enabled = False
Me.Result_Incub.Enabled = False
Me.Neutralising_Ab_Test_Dt.Enabled = False
Me.OD_Neut.Enabled = False
Me.Cutoff_OD_Neut.Enabled = False
Me.Result_Neut.Enabled = False
End If
End Sub
can anobody help.