Hi,
I currently have a spreadsheet whereby I would like to use the following code however im unsure on how to create the IF statement.
Range("L940").Select
If ActiveCell Like "*" And ActiveCell.Offset(0, 1).Range("A1").Value And " " And "*" Then
MsgBox ("correct")
Else
MsgBox ("incorrect")
End If
The above statement currently produces an error.
Its meant to say if activecell is like the cell next to it with a wild card either side then the msgbox appears
Any help would be appreciated.
Regards
Andy
I currently have a spreadsheet whereby I would like to use the following code however im unsure on how to create the IF statement.
Range("L940").Select
If ActiveCell Like "*" And ActiveCell.Offset(0, 1).Range("A1").Value And " " And "*" Then
MsgBox ("correct")
Else
MsgBox ("incorrect")
End If
The above statement currently produces an error.
Its meant to say if activecell is like the cell next to it with a wild card either side then the msgbox appears
Any help would be appreciated.
Regards
Andy