ChrisNeal1990
Registered User.
- Local time
- Today, 02:59
- Joined
- Mar 25, 2017
- Messages
- 11
Hi,
Does anyone know a way I can prevent referencing the same control when using the IF function in VBA.
The below does not work
Private Sub comboboxA_AfterUpdate()
If comboboxA = 1 Or 100 Or 24 Then
MsgBox "sdffds", vbOKOnly, "dfgdsfg"
End If
End Sub
Whereas the below does work
Private Sub comboboxA_AfterUpdate()
If comboboxA = 1 Or comboboxA = 100 Or comboboxA = 24 Then
MsgBox "sdffds", vbOKOnly, "dfgdsfg"
End If
End Sub
Does anyone know a way I can prevent referencing the same control when using the IF function in VBA.
The below does not work
Private Sub comboboxA_AfterUpdate()
If comboboxA = 1 Or 100 Or 24 Then
MsgBox "sdffds", vbOKOnly, "dfgdsfg"
End If
End Sub
Whereas the below does work
Private Sub comboboxA_AfterUpdate()
If comboboxA = 1 Or comboboxA = 100 Or comboboxA = 24 Then
MsgBox "sdffds", vbOKOnly, "dfgdsfg"
End If
End Sub