随笔分类 -  C#

c#
摘要:http://www.codeproject.com/Articles/6259/Monitoring-network-speed 阅读全文
posted @ 2015-07-03 20:36 b̶i̶n̶g̶.̶ 阅读(162) 评论(0) 推荐(0) 编辑
摘要:http://www.cnblogs.com/WangJinYang/p/3553792.html 阅读全文
posted @ 2015-06-09 21:51 b̶i̶n̶g̶.̶ 阅读(143) 评论(0) 推荐(0) 编辑
摘要:/// /// 对集合进行排序,如 /// List users=new List(){.......} /// ListSorter.SortList,Person>( users,"Age",SortDirection.Ascending); /// pub... 阅读全文
posted @ 2015-06-09 21:42 b̶i̶n̶g̶.̶ 阅读(332) 评论(0) 推荐(0) 编辑
摘要:class Program { static void Main(string[] args) { var array = new[] { 11, 3, 24, 5, 0, 2, 4, 6, -1, 101, 101, 5 }; ... 阅读全文
posted @ 2015-06-09 21:29 b̶i̶n̶g̶.̶ 阅读(173) 评论(0) 推荐(0) 编辑
摘要:1B (Byte 字节)=8b (bit 位)1KB (Kilobyte 千字节)=1024B,1MB (Megabyte 兆字节 简称“兆”)=1024KB,1GB (Gigabyte 吉字节 又称“千兆”)=1024MB,1TB (Trillionbyte 万亿字节 太字节)=1024GB,1P... 阅读全文
posted @ 2015-05-11 08:26 b̶i̶n̶g̶.̶ 阅读(649) 评论(0) 推荐(0) 编辑
摘要:using System;using System.IO;using System.Security.Cryptography;using System.Text; public class MD5Code { /// /// Get 文件的MD5校验码 ... 阅读全文
posted @ 2015-05-05 15:54 b̶i̶n̶g̶.̶ 阅读(1142) 评论(0) 推荐(0) 编辑
摘要:public class CheckComputerFreeState { /// /// 创建结构体用于返回捕获时间 /// [StructLayout(LayoutKind.Sequential)] ... 阅读全文
posted @ 2015-04-13 09:49 b̶i̶n̶g̶.̶ 阅读(1297) 评论(0) 推荐(0) 编辑
摘要:LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); 阅读全文
posted @ 2015-04-09 18:55 b̶i̶n̶g̶.̶ 阅读(161) 评论(0) 推荐(0) 编辑
摘要:1 #region 获取时间差string GetTime(BsonString getTime) 2 /// 3 /// 获取时间差 4 /// 5 /// 数据库时间 6 /// 时间差 7 ... 阅读全文
posted @ 2015-03-12 09:53 b̶i̶n̶g̶.̶ 阅读(1847) 评论(0) 推荐(0) 编辑
摘要:#region 排序获取集合 static List GetPagerWithGroup(string connectionString, string databaseName, string collectionName, IMongoQuery param, GroupByBuild... 阅读全文
posted @ 2015-02-06 14:20 b̶i̶n̶g̶.̶ 阅读(575) 评论(1) 推荐(0) 编辑
摘要:using System;using System.IO;using System.Security.Cryptography;namespace RijndaelManaged_Example{ class RijndaelExample { public static ... 阅读全文
posted @ 2015-02-04 11:29 b̶i̶n̶g̶.̶ 阅读(746) 评论(0) 推荐(0) 编辑
摘要:Query.All("name", "a", "b");//通过多个元素来匹配数组 Query.In("name", "a", "b");//包括指定的所有值,可以指定不同类型的条件和值 Query.And(Query.EQ("na... 阅读全文
posted @ 2015-02-03 15:46 b̶i̶n̶g̶.̶ 阅读(329) 评论(0) 推荐(0) 编辑
摘要:C# var icon = System.Drawing.Icon.ExtractAssociatedIcon(@"filepath"); var m = new MemoryStream(); icon.Save(m); ... 阅读全文
posted @ 2015-02-02 15:01 b̶i̶n̶g̶.̶ 阅读(796) 评论(0) 推荐(0) 编辑
摘要:原文:1.http://www.cnblogs.com/BoyceYang/p/3711343.html2.http://www.cnblogs.com/lhking/p/3660182.html3.http://blog.csdn.net/kendo3065/article/details/399... 阅读全文
posted @ 2015-01-16 21:37 b̶i̶n̶g̶.̶ 阅读(131) 评论(0) 推荐(0) 编辑
摘要:主构造函数自动属性初始化表达式尤其适合与主构造函数结合使用。主构造函数为降低常见对象模式的繁琐程度提供了一种方法。此功能自五月以来已显著改进。更新包括:主构造函数的可选实现主体:这将支持此前不受支持的主构造函数参数验证和初始化等。取消字段参数:通过主构造函数参数对字段进行声明。(不将此功能按照已定义... 阅读全文
posted @ 2015-01-16 21:25 b̶i̶n̶g̶.̶ 阅读(380) 评论(0) 推荐(0) 编辑
摘要:自动属性初始化表达式有过正确实现结构经验的所有 .NET 开发人员无疑都为一个问题所困扰:需要使用多少语法才能使类型固定不变(为 .NET 标准建议的类型)。此问题实际上是只读属性存在的问题:定义为只读的支持字段构造函数内支持字段的初始化属性的显式实现(而非使用自动属性)返回支持字段的显式 gett... 阅读全文
posted @ 2015-01-16 21:18 b̶i̶n̶g̶.̶ 阅读(318) 评论(0) 推荐(0) 编辑
摘要:概述尽管 C# 6.0 尚未完成,但现在这些功能正处于接近完成的关键时刻。自 2014 年 5 月发布文章“C# 6.0 语言预览版”(msdn.microsoft.com/magazine/dn683793.aspx) 以来,下一版本的 Visual Studio 的 CTP3 版本中对 C# 6... 阅读全文
posted @ 2015-01-16 20:57 b̶i̶n̶g̶.̶ 阅读(529) 评论(0) 推荐(0) 编辑
摘要://加载计算机上可用的字体 public void LoadFonts(object ietfLanguageTag) { try { var sysFonts = Fonts.Sy... 阅读全文
posted @ 2015-01-14 10:21 b̶i̶n̶g̶.̶ 阅读(328) 评论(0) 推荐(0) 编辑
摘要:http://www.cnblogs.com/lonelyxmas/archive/2009/11/10/1599707.html 阅读全文
posted @ 2014-12-21 21:38 b̶i̶n̶g̶.̶ 阅读(278) 评论(0) 推荐(0) 编辑
摘要:原文:http://www.cnblogs.com/zengxiangzhan/archive/2010/01/30/1659687.html 阅读全文
posted @ 2014-12-18 14:36 b̶i̶n̶g̶.̶ 阅读(156) 评论(0) 推荐(0) 编辑