string strTest1 = ""; string strTest2 = ""; string[] strRe = System.Text.RegularExpressions.Regex.Split(“字符串”, @"要分割字符"); strTest1 = strRe[0].Trim().ToString(); strTest2 = strRe[1].Trim().ToString();string test=“123A|1231”.Replace("|","");