I have 3 combo boxes cboCustomer2, cbospec2 and cbotest . When cbocustomer is selected it queries the cbospec which in turn queries the cbotest. Problem is if a user selects cboCustomer2, cbospec2 & cbotest then they change the cboCustomer2. The cbospec clears but the cbotest doesn't.
Help:
these are afterupdate:
If IsNull(Me.cboCustomer2) Then
' clear the bottom combo's current value
Me.cboSpec2 = Null
Me.cboTest = Null
' lock and disable the bottom combo
Me.cboSpec2.Enabled = False
Me.cboSpec2.Locked = True
Me.cboTest.Enabled = False
Me.cboTest.Locked = True
Else
' unlock and enable the bottom combo
Me.cboSpec2.Enabled = True
Me.cboTest.Enabled = True
' requery bottom combo based on the selection
' in the top combo
Me.cboCustomer2.Requery
Me.cboSpec2.Requery
Me.cboTest.Requery
End If
End Sub
If IsNull(Me.cboTest) Then
' clear the bottom combo's current value
Me.cboTest = Null
' lock and disable the bottom combo
Me.cboTest.Enabled = False
Me.cboTest.Locked = True
Else
' unlock and enable the bottom combo
Me.cboTest.Enabled = True
Me.cboTest.Locked = False
' requery bottom combo based on the selection
' in the top combo
Me.cboTest.Requery
End If
End Sub
Help:
these are afterupdate:
If IsNull(Me.cboCustomer2) Then
' clear the bottom combo's current value
Me.cboSpec2 = Null
Me.cboTest = Null
' lock and disable the bottom combo
Me.cboSpec2.Enabled = False
Me.cboSpec2.Locked = True
Me.cboTest.Enabled = False
Me.cboTest.Locked = True
Else
' unlock and enable the bottom combo
Me.cboSpec2.Enabled = True
Me.cboTest.Enabled = True
' requery bottom combo based on the selection
' in the top combo
Me.cboCustomer2.Requery
Me.cboSpec2.Requery
Me.cboTest.Requery
End If
End Sub
If IsNull(Me.cboTest) Then
' clear the bottom combo's current value
Me.cboTest = Null
' lock and disable the bottom combo
Me.cboTest.Enabled = False
Me.cboTest.Locked = True
Else
' unlock and enable the bottom combo
Me.cboTest.Enabled = True
Me.cboTest.Locked = False
' requery bottom combo based on the selection
' in the top combo
Me.cboTest.Requery
End If
End Sub