码迷,mamicode.com
首页 >  
搜索关键字:linq    ( 6890个结果
linq常用
ToList()什么时候用?1.当需要对返回的结果进行操作时(比如foreach()操作),可以将这个结果先ToList(),这样可以提高程序运行速度。2.当不需要对结果进行操作时,直接返回IEnumerable对象即可。?:运算符需要返回的结果是Nullable类型的值时怎么办?decimal? ...
分类:其他好文   时间:2014-05-09 18:17:48    阅读次数:265
C#将数据库导出成Excel,再从Excel导入到数据库中。
using System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Data.SqlClient;using System.IO;namespace CindyDatabaseP...
分类:数据库   时间:2014-05-09 11:37:48    阅读次数:378
C# Copy 文件
using System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Threading.Tasks;using System.IO;namespace DirectoryCopy...
分类:其他好文   时间:2014-05-08 20:30:59    阅读次数:381
C# 访问一个页面,并根据该页面上的a标签递归访问每个页面
using System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Threading.Tasks;using System.IO;using System.Net;using ...
分类:其他好文   时间:2014-05-08 20:30:34    阅读次数:389
C#:复选框操作类
using System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Windows.Forms;namespace Common{ /// /// 复选框操作类 ...
分类:其他好文   时间:2014-05-07 20:22:28    阅读次数:345
XmlSerialization 序列化与反序列化
using System;using System.Collections;using System.Collections.Generic;using System.IO;using System.Linq;using System.Text;using System.Threading.Task...
分类:其他好文   时间:2014-05-07 19:10:55    阅读次数:387
SynchronizationContext的研究之一(非WPF及Forms)
1 using System; 2 using System.Collections.Generic; 3 using System.Linq; 4 using System.Text; 5 using System.Threading; 6 7 8 namespace Synchroniza...
分类:其他好文   时间:2014-05-07 02:18:18    阅读次数:287
.Net并行编程之二:并行循环
本篇内容主要包括:1.能够转化为并行循环的条件2.并行For循环的用法:Parallel.For3.并行ForEach的用法Parallel.ForEach4.并行LINQ(PLINQ)的用法AsParallel()5.并行中断与并行停止的用法与区别6.外部控制循环取消的方法(Break,Stop)...
分类:Web程序   时间:2014-05-07 00:33:18    阅读次数:441
.Net平台下实例类型无法转换成接口类型?
首先这种情况出现在应用程序启动前的方法里面。本想通过发射来实现一些功能。谁知道被这个坑了。碰到这种问题。已经相当无语了。同时也不知道该如何解决。望有能之士帮忙解答using System;using System.IO;using System.Linq;using System.Reflectio...
分类:Web程序   时间:2014-05-04 20:24:23    阅读次数:433
pageHtml.cs
using System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Web;using System.Collections.Specialized;namespace NewX...
分类:Web程序   时间:2014-05-04 19:04:08    阅读次数:437
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!