Android Question Like Syntax

ronell

Well-Known Member
Licensed User
Longtime User
B4X:
 Dim text1, text2 As String
    text1 = "a"
    text2 = "b"
 
    Log(text1.CompareTo(text2))

aaaa.png

try those ..
 
Upvote 0

Star-Dust

Expert
Licensed User
Longtime User
I personally use string.contains. I you want to check a similar like "%MAURO%" you can use if mystring.contains("MAURO")
For like "%MAURO%" you can use if mystring.IndexOf("MAURO")>-1 then
and For Don't like "%MAURO%" :p you can use if mystring.IndexOf("MAURO")=-1 then
 
Upvote 0
Top