Nested AND OR expressions
Or maybe this:
---------------------
Sub Test()
If [J1] = 11 Then
If [E1] = "1bx" Or [E1] = "2bx" Or [E1] = "3bx" Then
Result = 1
Else
Result = [J1]
End If
End If
End Sub
-------------
Micky
"Colin Hayes" wrote:
HI
I need to express something in VBA , and am having trouble with it.
I need to say this :
IF E1 CONTAINS "1bx" OR "2bx" OR "3bx" AND J1 =11 THEN PUT 1 , OTHERWISE
PUT J1
Can someone assist with some code to make this happen , please?
Grateful for any help.
Best Wishes
.
|