S
Sam Collett
Say I have
string foo = "Some text http://www.google.com more text
(e-mail address removed) more";
How could I parse it to find the links and store the results in a
string array, i.e. to get
string[] bar = ParseText(foo);
// bar[0] = "Some text ", bar[1] = "http://www.google.com", bar[3] = "
more text ", bar[4] = "(e-mail address removed)", bar[5] = " more"
The string variable 'foo' will have much more text than this. I don't
expect many hyperlinks, and in some cases none (so there will be a
'bar[0]', but not 'bar[1]')
string foo = "Some text http://www.google.com more text
(e-mail address removed) more";
How could I parse it to find the links and store the results in a
string array, i.e. to get
string[] bar = ParseText(foo);
// bar[0] = "Some text ", bar[1] = "http://www.google.com", bar[3] = "
more text ", bar[4] = "(e-mail address removed)", bar[5] = " more"
The string variable 'foo' will have much more text than this. I don't
expect many hyperlinks, and in some cases none (so there will be a
'bar[0]', but not 'bar[1]')