| 
 | 
Use regular expressions to remove white space characters (including spaces, carriage returns, tabs) in the string 
 
Quote 
using System.Text.RegulrExpression; 
 
Regex regex = new Regex ("\\s +"); 
string str = regex.Replace (textbox1.text, ""); 
 
Disadvantages: The spaces in the string will also be processed. |   
 
 
 
 |