快点告诉我!

解决方案 »

  1.   

    Private Function GetIndex(ByVal strS As String) As Long
        Dim lLen As Long
        Dim I As Long
        Dim strT As String
        
        lLen = Len(strS)
        For I = 1 To lLen
            strT = Mid(strS, I, 1)
            If Asc(strT) >= 48 And Asc(strT) <= 57 Then
                GetIndex = I
                Exit Function
            End If
        Next I
        GetIndex = -1
    End Function
      

  2.   

    楼上的使用的是自定义函数,你也可以用IsStr()函数
      

  3.   

    Rick110AAA(海牛猪猪)明白我的要求