> Is it possible to split a string at the combination "\r\n"
>
[quoted text clipped - 4 lines]
> domain
> isnetwork
Yes, but not with String.Split. Regex.Split will do it:
using System;
using System.Text.RegularExpressions;
class Test
{
static void Main()
{
string[] bits = Regex.Split ("hello\r\nthere\r\nJon",
"\\r\\n");
foreach (string bit in bits)
{
Console.WriteLine ("xxx"+bit+"xxx");
}
}
}
(Note that the "xxx" parts are for clarity of testing - because if it
got one bit which was "hello\r\nthere" it would still appear on two
lines!)
If you're doing this frequently in an app, it would be worth
precompiling the regular expression.

Signature
Jon Skeet - <skeet@pobox.com>
http://www.pobox.com/~skeet Blog: http://www.msmvps.com/jon.skeet
If replying to the group, please do not mail me too