G
Guest
I'm just trying to strip non numeric characters out of a string (phone
number) and the following snippet isn't working. It's pretty straight
forward and should working according to:
http://msdn.microsoft.com/library/d...ref/html/frlrfSystemStringClassTrimTopic2.asp
public string StripAplhanumeric(string sStrip)
{
string sStripLine =
@"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz!@#$%^&*(){}[]',<.>_-/?=+`~
";
string sRslt = sStrip.Trim((sStripLine.ToCharArray())) ;
return sRslt;
}
number) and the following snippet isn't working. It's pretty straight
forward and should working according to:
http://msdn.microsoft.com/library/d...ref/html/frlrfSystemStringClassTrimTopic2.asp
public string StripAplhanumeric(string sStrip)
{
string sStripLine =
@"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz!@#$%^&*(){}[]',<.>_-/?=+`~
";
string sRslt = sStrip.Trim((sStripLine.ToCharArray())) ;
return sRslt;
}