I have a drop down select list in a VBA form I would like to validate as soon the user clicks on it. It needs to check that a pre-requisite drop down has been filled already.
This is to avoid the user jumping ahead on the form because there are certain fields that need to be filled out first. My attempt so far is not working:
Private Sub cbo_moduleName_Click() If Len(cbo_moduleCode.Value) = 0 Then MsgBox ("Please select a module code") Exit Sub End If End Sub
cbo_moduleCodeon yourUserForm? What error message you getting? Can you provide a screenshot of yourUserFrom?cbo_moduleName_Enternotcbo_moduleName_GotFocus()