Is there any function similar to string range in vb.net 2.0 ??
What I am try to achieve here is to extract some text from a string with unknown length.
eg.
given string = text text text mytext1 text text text text mytext2 text text text text
expected string = mytext1 text text text text mytext2
So I have the indexes for "mytext1" and "mytext2". I am looking for a way to get the text that wrapped in between those two strings or indexes.
Thanks
Well, what’s wrong with
String.Substring? It works on indices so if you want to find text delimited by two words, you first need to find their respective indices usingString.IndexOf.(Note that
Tois a reserved word so I need to put the identifier in square braces … or use another identifier. ;-))