C# string.Split VS2005 cf

  • Thread starter Thread starter Jonas
  • Start date Start date
J

Jonas

I am trying to use the new string.Split function thats splits a string
delimited by another string. The function works fine in a Winform app, but
not in a Pocket Pc application. According to the product documentation this
function should be supported by the compact framework. Does anyone know
something about this?
 
Hi, Split function works for me in CF 2.0 inside VS.NET 2005 Beta2. I
use it this way:

userId = registryValue.Split('|')[0]; //registryValue is a string
containing '|' separator. This way I only take the first part of the
splitted string

Hope it helps. Regards.
 
..NETCF only supports the overload of this method which takes a char array -
not the string array version. You can either write your own method using
IndexOf and Substring, or use RegularExpressions.

Peter
 
Hi Peter.

Ok. It´s not a problem to use the char array. But it would have been nice to
have the overloads in CF to.

Thanks.
 
Back
Top