I want to remove a comma separated value from the string..
suppose I have a string like this
string x=\"r, v, l, m\"
and i want to
Just do something like:
List Items = x.Split(",").Select(i => i.Trim()).Where(i => i != string.Empty).ToList(); //Split them all and remove spaces Items.Remove("v"); //or whichever you want string NewX = String.Join(", ", Items.ToArray());