case
what about this:
Sub qq()
Dim MyCheck As String
MyCheck = Cells(1, 3).Value
Cells(1, 3).Select
If MyCheck = "ABoy" Then
ActiveCell.Offset(0, 1).Value = 10
ElseIf MyCheck Like "A*" Then
ActiveCell.Offset(0, 1).Value = 20
Else
ActiveCell.Offset(0, 1).Value = 99
End If
End Sub
|