摘要: _dic = _dic.OrderByDescending(x => x.Value).ToDictionary(x=>x.Key,x=>x.Value); var Num = _dic.ToList().Take(5).Select(a => a.Key.ToString()).ToArray() 阅读全文
posted @ 2016-09-09 14:20 会弹猫的吉他 阅读(3419) 评论(0) 推荐(0) 编辑
摘要: //过滤\n 转换成空 String withoutNString=message.Replace("\n", ""); //过滤\r 转换成空 String withoutRString = withoutNString.Replace("\r", ""); //过滤\t 转换成空 String  阅读全文
posted @ 2016-09-09 13:12 会弹猫的吉他 阅读(3559) 评论(0) 推荐(0) 编辑
摘要: 1,IP填错。2,防火墙太严。3,使用过别的VPN软件。4,服务器上服务里Protected Sqwerrage和Routing and Remote Access这两项是否启动。5,重启电脑,删除原来建好的,重新一个新的VPN连接。6,打开 开始-运行-输入cmd,输入命令ipconfig /fl 阅读全文
posted @ 2016-08-27 14:44 会弹猫的吉他 阅读(1176) 评论(0) 推荐(0) 编辑
摘要: // 时间戳转为C#格式时间 private DateTime StampToDateTime(string timeStamp) { DateTime dateTimeStart = TimeZone.CurrentTimeZone.ToLocalTime(new DateTime(1970, 1, 1)); lo... 阅读全文
posted @ 2016-08-27 14:05 会弹猫的吉他 阅读(215) 评论(0) 推荐(0) 编辑
摘要: HttpUtility.UrlDecode("\u4e0b\u6ce8\u903e\u65f6"); HttpUtility.UrlDecode("\\u5c1a\\u672a\\u5f00\\u76d8".Replace("\\", "%")); 阅读全文
posted @ 2016-08-25 09:33 会弹猫的吉他 阅读(1670) 评论(0) 推荐(0) 编辑
摘要: JObject jsonData = new JObject(); jsonData.Add("1", "1"); jsonData.Add("2", "1"); using (IEnumerator> enumerator = jsonData.GetEnumerator()) { if (enumerator.MoveNext()) { K... 阅读全文
posted @ 2016-08-24 10:42 会弹猫的吉他 阅读(11372) 评论(0) 推荐(0) 编辑
摘要: //System.Environment.Exit(0); //Process.GetCurrentProcess().Kill(); //System.Threading.Thread.CurrentThread.Abort(); System.Diagnostics.Process.GetCurrentProcess().Kill(); Application.Exi... 阅读全文
posted @ 2016-08-23 14:22 会弹猫的吉他 阅读(668) 评论(0) 推荐(0) 编辑
摘要: using ConsoleApplication1; using System; using System.Collections.Generic; using System.Net; using System.Net.Sockets; using System.Text; using System 阅读全文
posted @ 2016-08-19 09:00 会弹猫的吉他 阅读(242) 评论(0) 推荐(0) 编辑
摘要: 窗体FormBorderStyle属性设置为:FixedSingle,再把最大化禁用就可以了 阅读全文
posted @ 2016-08-18 09:30 会弹猫的吉他 阅读(328) 评论(0) 推荐(0) 编辑
摘要: Visual Studio里的摘要:处理当前在消息队列中的所有 Windows 消息。 交出CPU控制权,让系统可以处理队列中的所有Windows消息,比如在大运算量循环内,加Application.DoEvents可以防止界面停止响应,因为winform的消息循环是一个线程来处理,那么假如你的某个 阅读全文
posted @ 2016-08-17 15:49 会弹猫的吉他 阅读(3224) 评论(0) 推荐(0) 编辑