Quantcast
Channel: VBForums - Visual Basic 6 and Earlier
Viewing all articles
Browse latest Browse all 21207

[RESOLVED] string manipulation

$
0
0
Hi guys, I have this following string:

"testing|test|Name|msword|Looking|aaa"

I want to be able to get the "msword" out of that above string after the "Name|"

Also, if the string becomes like this:

"testing|test|Name|msword|"

I want to be able to get the "msword" out of that above string after the "Name|" as well -

so the format will be always Name|something....

I tried this, but it only works for 2nd scenario but no the first scenario.

Code:

Right$(sCommand, Len(sCommand) - InStrRev(sCommand, "|"))

Viewing all articles
Browse latest Browse all 21207


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>