摘要: 1.JavaScript数组与对象的声明<script type="text/javascript"> //数据声明方式 function testArray(){ var arr=['a','b','c']; var arr2=new Array('a1','b1','c1'); for(var i=0;i<arr.length;i++){ alert(arr[i]+" "+arr2[i]); } } //对象声明方式 function.. 阅读全文
posted @ 2012-09-04 15:47 小众 阅读(405) 评论(0) 推荐(0) 编辑
摘要: select count(1) from syscolumns where id = object_id('tbname')或者select * from syscolumns where id = object_id('tbname')或SELECT MAX(colid) FROM syscolumns WHERE id=OBJECT_ID('table') 阅读全文
posted @ 2012-02-29 10:53 小众 阅读(1142) 评论(0) 推荐(0) 编辑
摘要: C#追加文件StreamWritersw=File.AppendText(Server.MapPath(".")+"\\myText.txt");sw.WriteLine("追逐理想");sw.WriteLine("kzlll");sw.WriteLine(".NET笔记");sw.Flush();sw.Close();C#拷贝文件stringOrignFile,NewFile;OrignFile=Server.MapPath(".")+"\\myText.txt& 阅读全文
posted @ 2011-12-26 17:04 小众 阅读(283) 评论(0) 推荐(0) 编辑
摘要: 这个日志文件存放在程序的bin文件夹下得Debug中static private string logpathlog = AppDomain.CurrentDomain.BaseDirectory + "log.txt"; static public void writelog(string classname) { string path = logpathlog; if (!File.Exists(path)) { // Create a file to write ... 阅读全文
posted @ 2011-12-01 15:05 小众 阅读(4135) 评论(0) 推荐(1) 编辑
摘要: 1.创建测试环境View Code create database DBTestuse DBTest--创建测试表create table pagetest(id int identity(1,1) not null,col01 int null,col02 nvarchar(50) null,col03 datetime null)2.插入10000条数据View Codefloor(rand() 一个随机函数3.分页sql,下面例子是每页50条,198*50=9900,取第199页数据 View Code4.ROWNUMBER的方式封装到存储过程。View Code CREATE proc 阅读全文
posted @ 2011-11-04 16:15 小众 阅读(178) 评论(0) 推荐(0) 编辑
摘要: 需求:创建一个xml文档,其格式为:View Code <?xml version="1.0" encoding="gb2312" ?><chart caption='个人一年内月度得分统计' xAxisName='月份' yAxisName='分值' numberPrefix=''> <set label='1月' value='14400' /> <set label='2月' value=' 阅读全文
posted @ 2011-10-17 16:18 小众 阅读(249) 评论(0) 推荐(0) 编辑
摘要: 一、DataTable简介 (1)构造函数 DataTable() 不带参数初始化DataTable 类的新实例。 DataTable(string tableName) 用指定的表名初始化DataTable 类的新实例。 DataTable(string tableName, string tableNamespace)用指定的表名和命名空间初始化DataTable 类的新实例。 (2) 常用属性 CaseSensitive 指示表中的字符串比较是否区分大小写。 ChildRelations 获取此DataTable 的子关系的集合。 Columns获取属于该表的列的集合。 ... 阅读全文
posted @ 2011-10-17 16:09 小众 阅读(382) 评论(0) 推荐(0) 编辑
摘要: View Code private void CreateTable() { try { PAP_EvaluatioinScoreBLL bll = new PAP_EvaluatioinScoreBLL(); DataTable dt = new DataTable(); dt = bll.GetEvaluationYearavgScore(userId, year, month, Type); TabStat.Rows.Clear(); Table... 阅读全文
posted @ 2011-10-14 09:54 小众 阅读(389) 评论(0) 推荐(0) 编辑