How to find the index of the last occurrence of one string within another from specific index in VB.NET

1 Answer

0 votes
Imports System
 
Public Class Test
    Public Shared Sub Main()
        Dim s As String = "java vb.net c# c++ vb.net c python vb.net"
 
        Dim search As String = "vb"
 
        Dim index As Integer = InStrRev(s, search, 30)
         
        Console.WriteLine(index)
    End Sub
End Class
 
 
 
 
' run:
'
' 20
'

 



answered Nov 19, 2021 by avibootz
...