by SAW Solutions (1 Submission)
Category: String Manipulation
Compatability: VB 6.0
Difficulty: Unknown Difficulty
Originally Published: Wed 14th April 2004
Date Added: Mon 8th February 2021
Rating: (1 Votes)
Get 3 different values from 1 string, in the easy-mode! The values are seperated with a ? symbol :) Very Easy!
Dim FromUser As String
Dim ToUser As String
Dim InMsg As String
Dim MsgPart1 As String
Dim MsgPart2 As String
Dim MsgPart3 As String
Dim MsgPart4 As String
MsgPart1 = Left(txt2Send, InStr(1, txt2Send, "ø"))
MsgPart2 = Right(txt2Send, Len(txt2Send) - Len(MsgPart1))
MsgPart3 = Left(MsgPart2, InStr(1, MsgPart2, "ø"))
MsgPart4 = Right(MsgPart2, Len(MsgPart2) - Len(MsgPart3))
FromUser = Left(MsgPart1, Len(MsgPart1) - 1)
ToUser = Left(MsgPart3, Len(MsgPart3) - 1)
InMsg = Left(MsgPart4, Len(MsgPart4))
MsgBox "FROMUSERNAME: " & FromUser
MsgBox "TOUSERNAME: " & ToUser
MsgBox "Message: " & InMsg
' This code was written by Sikke Ale Werkhoven... Took me 20 min to figure this method out :)
No comments have been posted about Get 3 different values from 1 string, in the easy-mode! The values are seperated with a ? symbol :). Why not be the first to post a comment about Get 3 different values from 1 string, in the easy-mode! The values are seperated with a ? symbol :).