Variant使うならこうか?あんまメリットないな
Sub maxtext()
 Const kaisirow As Long = 5003

 Dim X As Variant
 Dim MaxValue As Double
 With WorksheetFunction
  X = .Transpose(Cells(kaisirow, 1).Resize(10, 1).Value)
  MaxValue = .Max(X)
 End With

 Dim i As Long
 For i = 1 To UBound(X)
  If IsNumeric(i) Then
   If i = MaxValue Then MsgBox i
  End If
 Next

End Sub