1.判读是否为数字 System.Text.RegularExpressions.Regex reg1 = new System.Text.RegularExpressions.Regex(@"^[-]?\d+[.]?\d*$");if(reg1.IsMatch(str)){//数字}else{//非数字}