A | |
1 | |
2 | |
3 | |
4 | Baseball |
5 | |
6 | Beach |
7 |
=MATCH("Baseball", A2:A29, 0)-MATCH("Beach", A2:A29, 0)-1
Sub Maybe_C()
Dim i As Long, ii As Long
i = ActiveSheet.Columns(1).Find("Beach").Row
ii = ActiveSheet.Columns(1).Find("Baseball").Row
MsgBox IIf(ii > i, ii - (i + 1), i - (ii + 1))
End Sub