摘要: /// /// 判断输入的字符串是不是数字,不是返回True,否则返回False /// /// /// public static bool IsNum(string text) //http://wenwen.soso.com/z/q120543222.htm { for (int i = 0; i text.Length; i++) { if (!Char.IsNumber(text, i)) { return true; //输入的不是数字 } } return false; //否则是数字 } 自己又做了 阅读全文
posted @ 2010-07-29 17:32 叮当小马 阅读(5832) 评论(0) 推荐(0)
摘要: 转贴:2010年7月29日17:12:36<script type="text/javascript">/*判断文本框中输入的值是不是正整数*/function check(){ var t=document.getElementById("txtStudentNo").value;if(t.length<=0){alert("人数不能为空!"); }else{ for(var ... 阅读全文
posted @ 2010-07-29 17:13 叮当小马 阅读(2235) 评论(0) 推荐(0)