⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 code117a.txt

📁 VB大全(精华版)源代码
💻 TXT
字号:
Public Function r_FindString(ByVal srchString As String, ByVal _
    fndString As String, ByVal strEnd As Integer) as Integer
  
  Dim I As Integer, LastChar As Integer
  Dim CurrentPos As Integer, LastPos As Integer

  If strEnd > 0 then
    LastChar = strEnd
  Else
    LastChar = Len(srchString)
  End If

  Next_Pos = 0

  Do
    Current_Pos = Next_Pos
    Next_Pos = InStr(Current_Pos + 1, srchString, fndString)
  Loop Until (Next_Pos = 0) Or (Next_Pos > LastChar)

  If Current_Pos > 0 Then
    r_FindString = Current_Pos
  Else
    r_FindString = -1
  End If
End Function

Public Sub Main()
  Dim SearchString As String, SearchFor As String 
  Dim Position As Integer

  SearchString ="Tips for eating tri-tip steak."
  SearchFor = "tip"

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -