MChancellor
Technical User
Hi... I'm needing some help. I have a piece of code that used to work, that now no longer functions. From what I can tell, the code should work, but it doesn't. If you all can help me figure out what I'm missing, that would be great.
I helped build a small database for a nonprofit company, but it was an "on the side" thing, and I'm not there all the time. I got a call from my contact there this past week saying that one of their employees had used another employee's user id and password and had messed up a checkbox on one of the forms. No one knows what she did, but it doesn't work now.
I went in yesterday to see if I could solve the problem. I looked at the code, and it was fine. I checked to make sure that the checkbox was enabled on the form, and the properties portion of things looked fine. A similar piece of code worked fine when I tried it.
The checkbox that isn't working is on a subform on a main form. It is tied to a drop down on the subform. Based on what is chosen in the subform, the checkbox is either enabled or disabled. Here's the code that controls this functionality (which used to work fine):
Private Sub Client_Status_AfterUpdate()
If [Client Status].Value = "Dropped" or [Client Status].Value = "Completed" or [Client Status].Value = "No Show" Then
[Referral Source Notified].Enabled = True
Else: [Referral Source Notified].Enabled = False
End If
End Sub
I'm baffled by all this, because from what I can tell, the code is fine, the properties on the check box look to be set properly, and since a similar piece of code works, I can't understand why this one isn't. I have the same piece of code inserted into the Form_Load and Form_GotFocus methods for the same form. None of them work.
If anyone can help me with this, I'd REALLY appreciate it. The only thing I haven't checked is the permissions on the user, but I have the user set up as an admin, so I don't think that would be an issue. Also, we tried it on another users account, and it didn't work on that either.
Any help would be greatly appreciated.
Misti
I helped build a small database for a nonprofit company, but it was an "on the side" thing, and I'm not there all the time. I got a call from my contact there this past week saying that one of their employees had used another employee's user id and password and had messed up a checkbox on one of the forms. No one knows what she did, but it doesn't work now.
I went in yesterday to see if I could solve the problem. I looked at the code, and it was fine. I checked to make sure that the checkbox was enabled on the form, and the properties portion of things looked fine. A similar piece of code worked fine when I tried it.
The checkbox that isn't working is on a subform on a main form. It is tied to a drop down on the subform. Based on what is chosen in the subform, the checkbox is either enabled or disabled. Here's the code that controls this functionality (which used to work fine):
Private Sub Client_Status_AfterUpdate()
If [Client Status].Value = "Dropped" or [Client Status].Value = "Completed" or [Client Status].Value = "No Show" Then
[Referral Source Notified].Enabled = True
Else: [Referral Source Notified].Enabled = False
End If
End Sub
I'm baffled by all this, because from what I can tell, the code is fine, the properties on the check box look to be set properly, and since a similar piece of code works, I can't understand why this one isn't. I have the same piece of code inserted into the Form_Load and Form_GotFocus methods for the same form. None of them work.
If anyone can help me with this, I'd REALLY appreciate it. The only thing I haven't checked is the permissions on the user, but I have the user set up as an admin, so I don't think that would be an issue. Also, we tried it on another users account, and it didn't work on that either.
Any help would be greatly appreciated.
Misti