Back to code for cascading combo box
I have redone this code a million times...I'm losing it! I changed the name of the combo boxes to cboDenialCat and cboRoot Cause. When I enter in the code below I get this error message 'Compile Error Sub or function not defined':
Private Sub cboDenialCat_AfterUpdate()
Me!cboRootCause = Null
If IsNull(cboDenialCat) Then
Me!cboDenialCat.SetFocus
Me!cboRootCause.Enabled = False
Else
Me!cboRootCause.Enabled = True
Me!cboRootCause.RowSource = ReplaceWhereClause(Me!cboRootCause.RowSource, _
"Where Root Cause = " & Me!cboDenialCat)
Me!cboRootCause.Requery
End If
End Sub
I thought by renaming the combo boxes it would help. I'm so confused. I also don't know if the lookup table is what I need (if I could even get it to work) because we also want the ability for the user to enter in information for the Reason (under Root Cause table).
|