摘要:
声明为:static 的量变 会一直保存在内存中,应尽量少用如果页面中(Web 页面)千万别用静态变量. 因为,静态变量保存在服务器的内存中,只有当服务器关闭时,才会消失. 而页面的生命周期.... 阅读全文
摘要:
public static class ExtensionString { public static int ToInt(this string str) { int ret = 0; if (str != null && str.Length > 0) { str = str.Replace(",", string.Empty); int.TryParse(str, ou... 阅读全文
摘要:
不要写太多的脚本,因为这样客户要下载太段的脚本文件 阅读全文
摘要:
//在Div中绑定数据: $(document).ready(function(){ $("#divSs").load("Default.aspx"); }); 阅读全文
摘要:
function showOtherNeeds(obj){if(obj.checked){document.getElementById("<%=txtRequestOther.ClientID %>").style.display="block"; }else{document.getElementById("<%=txtRequestOther.ClientID %>"... 阅读全文
摘要:
1.下面列出了一些判读数值类型的正则表达式 "^\\d+$" //非负整数(正整数 + 0) "^[0-9]*[1-9][0-9]*$" //正整数 "^((-\\d+)|(0+))$" //非正整数(负整数 + 0) "^-[0-9]*[1-9][0-9]*$" //负整数 "^-?\\d+$" //整数 "^\\d+(\\.\\d+)?$" //非负浮点数(正浮点数 + 0) ... 阅读全文
摘要:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><title>... 阅读全文
摘要:
//验证输入必须为数字 function CheckNumber(theForm) { if (isNaN(theForm.txtNumber.value)){ alert("必须输入数字"); theForm.txtNumber.focus(); return false; } } function isNaN(String val) { return val.match(new RegExp(... 阅读全文
摘要:
insert into a values('aaaaa') print @@identity; //打印刚生成的主键值.**update a set c='AAAAAAAAAAAA' where b=15print @@identity; 阅读全文
摘要:
DECLARE@pagenum INT,@pagesize INTSET @pagenum = 2SET @pagesize = 3SELECT * FROM (SELECT ROW_NUMBER() OVER(ORDER BY b DESC) AS rownum,c FROM a) AS DWHERE rownum BETWEEN (@pagenum-1)*@pagesize+1 AND @pa... 阅读全文