上一页 1 ··· 6 7 8 9 10 11 12 13 14 ··· 21 下一页
摘要: void ExportExcel() { DataGrid outGrid = new DataGrid(); outGrid.DataSource = ExportTable(); outGrid.DataBind(); outGrid.HeaderStyle.BackCo... 阅读全文
posted @ 2013-03-21 10:34 Yu 阅读(1519) 评论(0) 推荐(0) 编辑
摘要: XAML XAML是基于XML的,它是WPF外在的表现形式。 XAML是一个纯粹的标记语言,这也就意味着某个元素要实现一个事件的处理时,需要在该元素中通过特定的属性来指定相应的事件处理方法名, 而真正的事件处理逻辑你可以通过C#或者VB.NET语言进行实现(代码后置方式),我们是没有办法通过XAML 阅读全文
posted @ 2013-03-19 09:39 Yu 阅读(377) 评论(0) 推荐(0) 编辑
摘要: using (ExcelPackage excelPackage = new ExcelPackage(new FileInfo(xlsxfullname))){ ExcelWorkbook wp = excelPackage.Workbook; ExcelWorksheet sh = wp.Worksheets[sheetname]; int col = 1; //1 为起始列 int rowindex = 1; //1为起始行 while (... 阅读全文
posted @ 2013-03-07 09:06 Yu 阅读(421) 评论(0) 推荐(0) 编辑
摘要: SqlParameter[] parms = new SqlParameter[2];SqlParameter id = new SqlParameter("ID", "11a44466-6d9c-4c7e-b9e4-5a1369061119");id.SqlDbType=SqlDbType.NVarChar;id.Size = 128;parms[0] = id; var outParam = new SqlParameter();outParam.ParameterName = "Name";outParam.SqlDbType 阅读全文
posted @ 2013-02-28 10:05 Yu 阅读(2976) 评论(1) 推荐(0) 编辑
摘要: Array.prototype.noRepeated=function(){ var newArray=[], flags={}; for (var i=0;i<this.length;i++){ var item= this[i]; if (!flags[item]) { newArray.push(item); flags[item] = true; } } return newArray; } var a={"a":"0","b":"OK","c":[{"Account&q 阅读全文
posted @ 2013-02-26 15:46 Yu 阅读(185) 评论(0) 推荐(0) 编辑
摘要: 1. 减少HTTP请求次数合并图片、CSS、JS,改进首次访问用户等待时间。2. 使用CDN就近缓存==>智能路由==>负载均衡==>WSA全站动态加速3. 避免空的src和href当link标签的href属性为空、script标签的src属性为空的时候,浏览器渲染的时候会把当前页面的URL作为它们的属性值,从而把页面的内容加载进来作为它们的值。测试4. 为文件头指定Expires使内容具有缓存性。避免了接下来的页面访问中不必要的HTTP请求。5. 使用gzip压缩内容压缩任何一个文本类型的响应,包括XML和JSON,都是值得的。旧文章6. 把CSS放到顶部7. 把JS放到底 阅读全文
posted @ 2013-02-26 09:11 Yu 阅读(221) 评论(0) 推荐(0) 编辑
摘要: table{border-top:1px solid #6E7B8B; border-right:1px solid #6E7B8B;width:500px;}td{border-left:1px solid #6E7B8B; border-bottom:1px solid #6E7B8B;height:21px;width:200px;}1-11-21-31-42-12-22-32-43-13-23-33-4==============================================.table{display:table;border-top:1px solid #6E7B 阅读全文
posted @ 2013-02-15 15:12 Yu 阅读(306) 评论(3) 推荐(1) 编辑
摘要: DTD文件: (test.dtd)<!ELEMENT Products (Product)+><!ELEMENT Product (ProductName)+><!ATTLIST Product ProductID CDATA #REQUIRED><!ELEMENT ProductName (#PCDATA)>ENTITY文件:(test.ent)<!ENTITY ldquo "A"><!ENTITY rdquo "B">XML文件:(test.xml)<?xml versio 阅读全文
posted @ 2013-02-02 16:07 Yu 阅读(440) 评论(0) 推荐(0) 编辑
摘要: var columnTypes=[]; //创建数组//下面是columnTypes对象的属性, 不是 columnTypes里的成员columnTypes["name"] = "A"; //等同 columnTypes.name="A"; 也可以通过原型字义 Array.prototype.name="A", //但是由原型定义的属性,则对所有 Array对象都适用.columnTypes["age"] = 12;columnTypes["sex"] = "man 阅读全文
posted @ 2013-01-31 15:06 Yu 阅读(324) 评论(0) 推荐(0) 编辑
摘要: Code First1. 基于Model中 字段 ID/ [className]+ID / 某字段有[Key] , 来自动生成主键的, 如果没有将会报如标题的错. public class Order{ public int ID{get;set;} } public class Order{ public int OrderID{get;set;} } public class Order{ [Key] public int CustomID{get;set;} }2. 当需要复合主键时,则要在各个主键上加 [Key, Column(Order=0)], ... 阅读全文
posted @ 2013-01-30 10:54 Yu 阅读(2393) 评论(0) 推荐(0) 编辑
上一页 1 ··· 6 7 8 9 10 11 12 13 14 ··· 21 下一页