Dim username As String = "Username: user4eir7yhm"
Dim password As String = "Password: uh6r0cdh"
Dim getUser() As String
getUser = Regex.Split(" ", username.Trim) 'Trim to eliminate blank spaces at the beginning and at the end of the string to parse
Dim getpw() As String
getpw = Regex.Split(" ", password.Trim) 'Trim to eliminate blank spaces at the beginning and at the end of the string to parse
Log(getUser(1))
Log(getpw(1))
It come obvious that all the Username and Password strings must have all the same format:
just ONE blank space after the ":" and no blank spaces inside the string.
Dim username As String = "Username: user4eir7yhm"
Dim password As String = "Password: uh6r0cdh"
Dim getUser() As String
getUser = Regex.Split(" ", username.Trim) 'Trim to eliminate blank spaces at the beginning and at the end of the string to parse
Dim getpw() As String
getpw = Regex.Split(" ", password.Trim) 'Trim to eliminate blank spaces at the beginning and at the end of the string to parse
Log(getUser(1))
Log(getpw(1))
It come obvious that all the Username and Password strings must have all the same format:
just ONE blank space after the ":" and no blank spaces inside the string.
Dim username As String = "Username: user4eir7yhm"
Dim password As String = "Password: uh6r0cdh"
Dim getUser() As String
getUser = Regex.Split(":", username)
Dim getpw() As String
getpw = Regex.Split(":", password)
Log(getUser(1).Trim) 'eliminate all blank spaces
Log(getpw(1).Trim) 'eliminate all blank spaces