摘要: ifconfig Command Not Found 原因:centos7 minimal install 不安装net-tools 安装net-tool:yum install net-tools 替代命令:ip addr show 或者 ip route show option: -s (-st 阅读全文
posted @ 2019-06-13 02:21 楊柳 阅读(239) 评论(0) 推荐(0) 编辑
摘要: 原理: 利用Queque的先进先出性质, 每次访问 Page 时 Enqueue 当前时间,當 Queue 元素的个数不满足指定的限制次数时,可继续访问,退出判断; 否则取[Peek]队列首元素 ,判断当前时间与 取出的时间比较,若间隔大于指定时间,则说明特定时间内访问次数没有达到限制值,弹出[De 阅读全文
posted @ 2019-06-07 13:02 楊柳 阅读(608) 评论(0) 推荐(0) 编辑
摘要: 1. 下载安装Windbg http://www.windbg.org/ Debugging Tools for Windows 10 (WinDbg) 下载Windows 10 SDK 2. Create Dump File cpu 使用量过高时,任务管理器找到相应的进程并dump files。 阅读全文
posted @ 2019-06-05 16:50 楊柳 阅读(293) 评论(0) 推荐(0) 编辑
摘要: CentOS 阅读全文
posted @ 2019-05-15 22:13 楊柳 阅读(23663) 评论(0) 推荐(1) 编辑
摘要: Uri 方法獲取 Protocal Host Port 阅读全文
posted @ 2018-12-07 14:52 楊柳 阅读(255) 评论(0) 推荐(0) 编辑
摘要: If you're storing them as strings rather than bit patterns: IPv4 addresses consist of four 3-digit decimal characters with three . separators, so that 阅读全文
posted @ 2017-12-02 17:15 楊柳 阅读(1279) 评论(0) 推荐(0) 编辑
摘要: 1. 方式一 导入row,新表架构与原表相同,foreach前clone, newDataTable=oldDataTable.Clone(); 2. 方式二 CopyToDataTable 3. Add 4. DataView 5. Merge 6. 7. Linq 阅读全文
posted @ 2017-12-02 12:07 楊柳 阅读(308) 评论(0) 推荐(0) 编辑
摘要: Ctrl+Alt+L reformat CodeCtrl+shift+/ comment/uncomment lines and blocks(/**/) Ctr+/ comment/uncoment current line or blocks(//)Ctrl+D in the editor du 阅读全文
posted @ 2017-09-18 13:34 楊柳 阅读(324) 评论(0) 推荐(0) 编辑
摘要: 1. on new{o.field1, o.field2} equals new {p.field1, p.field2} 2. from m in table1 from n in table2 where m.id==n.id && m.code==n.code select new{...} 阅读全文
posted @ 2017-08-29 21:26 楊柳 阅读(297) 评论(0) 推荐(0) 编辑
摘要: 1. SQL 执行顺序 阅读全文
posted @ 2017-08-29 18:04 楊柳 阅读(161) 评论(0) 推荐(0) 编辑
摘要: 1.引用相关js 2.定义 id 为 editor1 的 area 3.替换 4. 赋值和取值 阅读全文
posted @ 2017-08-08 09:51 楊柳 阅读(161) 评论(0) 推荐(0) 编辑
摘要: 近日做项目,涉及多个数据库多个表的关联更新,因数据量巨大,逐条更新也很费时。于是就想用SqlDataAdapter 一次提交一批数据过去。以下是自己经历的坑: 1. table Merge 部分 Merge提示<target>.f_CBMoney 和 <source>.f_CBMoney 的属性冲突 阅读全文
posted @ 2017-08-05 22:51 楊柳 阅读(452) 评论(0) 推荐(0) 编辑
摘要: //获取源机器的协议 //获取绝对路径 //替换http为https 阅读全文
posted @ 2017-06-28 15:48 楊柳 阅读(2694) 评论(0) 推荐(0) 编辑
摘要: SELECT hostname,loginame,* FROM sys.sysprocesses; SELECT count(*),hostname FROM sys.sysprocesses where cmd='AWAITING COMMAND' group by hostname; SELECT count(*),hostname,loginame FROM sys.syspr... 阅读全文
posted @ 2016-07-25 15:37 楊柳 阅读(687) 评论(0) 推荐(0) 编辑
摘要: 一、Slunk是什么 Splunk是一个托管的一体化的日志文件管理工具。通过对日志进行高效索引,让管理员可以对日志各种情况进行搜索,并通过友好视图展现出来。统计关注时间段整体交易延时和交易量,依据来源、类型等多维度统计交易。制作成仪表板等网路监控平台,并可设置交易告警、系统告警、应用告警 二、Slu 阅读全文
posted @ 2016-07-17 20:55 楊柳 阅读(1261) 评论(0) 推荐(0) 编辑
摘要: https://blogs.msdn.microsoft.com/visualstudioalm/2013/01/30/getting-started-with-git-in-visual-studio-and-team-foundation-service/ 一. visualstudio.com 阅读全文
posted @ 2016-07-16 23:53 楊柳 阅读(4389) 评论(0) 推荐(0) 编辑
摘要: CodeSmith 部分学习 1. 注册子模板child.cst到主模板 2. 调用子模板并输出 3. 遍历TableCollection表,并输出表名 4. 遍历Table列,其中DataType2CSharpType为一个自定义方法 //数据库类型:DbType. private _; 5. ... 阅读全文
posted @ 2016-07-16 00:46 楊柳 阅读(228) 评论(0) 推荐(0) 编辑
摘要: Fiddlercore 使用说明Fiddlercore不保留session序列,因此要自己保存。并且要注意网页session不会被垃圾回收,因为oAllSessions List保持活动引用,因此要时常trim。另一种选择,若仅仅关系请求url或者请求头,只保存一个list<>而不是存储对全sess 阅读全文
posted @ 2016-07-14 21:24 楊柳 阅读(2705) 评论(0) 推荐(0) 编辑
摘要: public void WriteGameLog(string msg,string logType) { //创建log文件夹 string log_path = @"C://log"; if (!Directory.Exists(log_path)) Directory.CreateDirectory(log_path); //创建log... 阅读全文
posted @ 2016-07-13 09:53 楊柳 阅读(288) 评论(0) 推荐(0) 编辑
摘要: winform checkbox Checked属性与CheckedChanged事件的关系 注意 當 AutoCheck 屬性為 true (預設值) 時,當按一下 CheckBox 時,它便會自動選取或取消選取。否則,您必須在發生 Click 事件時,手動設定 Checked 屬性。https: 阅读全文
posted @ 2016-07-05 22:54 楊柳 阅读(4251) 评论(0) 推荐(0) 编辑
摘要: 【标题】:SQL varchar varchar(n)【日期】:2016-07-04【类别】:SQLSERVER【问题】:T-SQL 声明变量类型为varchar后执行插入语句插入不成功【原因】:声明变量varchar不带长度,sqlserver会默认长度1代替 http://sqlblog.com 阅读全文
posted @ 2016-07-04 14:47 楊柳 阅读(555) 评论(0) 推荐(0) 编辑
摘要: 平均分配算法1.看到一遍老外写的并行运算,里面有个平均分配,感觉比较好,记录下 //若11个元素,4个cpu,则分配数量为(2, 3, 3, 3), seqno: 0...3每次分配的起点终点表示区间为[count*seqno/cores, count*(seqno+1)/cores) 阅读全文
posted @ 2016-07-03 11:56 楊柳 阅读(8574) 评论(0) 推荐(0) 编辑
摘要: 1.MD5加密 System.Security.Cryptography.MD5.Create() is actually creating a MD5CryptoServiceProvider.MD5 is the base class and it's abstract. I'm guessin 阅读全文
posted @ 2016-06-29 22:30 楊柳 阅读(228) 评论(0) 推荐(0) 编辑
摘要: syncBackPro添加同步任务到一个任务组1.同步任务=》添加任务 填写【任务名称】,这是一个任务组不勾选=》您要创建何种任务,【备份,同步,镜像选 备份或镜像】=》源文件夹、目标文件夹,默认 硬盘、usb、闪存盘等=》完成=》选择要同步的源文件夹和目标文件夹,按键【选择子文件夹和文件】可以挑选 阅读全文
posted @ 2016-06-29 11:56 楊柳 阅读(3248) 评论(0) 推荐(0) 编辑
摘要: Environment.MachineName;System.Net.Dns.GetHostName();System.Windows.Forms.SystemInformation.ComputerName;System.Environment.GetEnvironmentVariable("CO 阅读全文
posted @ 2016-06-29 11:36 楊柳 阅读(209) 评论(0) 推荐(0) 编辑
摘要: 1.新建团队项目 视图 团队资源管理器 HOME主页下拉框 [设置]=》下拉选【项目和我的团队】=》下拉选【新建团队项目】 2.管理团队成员菜单 团队=》团队项目设置=》组成员资格 登陆web控制面板网页标签卡【安全性】 右侧团队项目 【成员】栏位,添加 windows成员或组 阅读全文
posted @ 2016-06-29 11:35 楊柳 阅读(182) 评论(0) 推荐(0) 编辑
摘要: There are some difference between KeyValuePair which is the generic version and DictionaryEntry which is non generic version. The advantage of using a 阅读全文
posted @ 2016-06-27 19:04 楊柳 阅读(305) 评论(0) 推荐(0) 编辑
摘要: protected void Down_Load(object sender, EventArgs e) { //create a stream for the file Stream stream = null; //this controls how many bytes to read at a time and send to the ... 阅读全文
posted @ 2016-06-22 23:45 楊柳 阅读(4161) 评论(0) 推荐(0) 编辑
摘要: 1. 对象初始化器 若定义匿名类型,则必须使用对象初始值设定项 public class StudentName{ // 默认构造函数 ,在对象初始化器初始化时触发 // 如果类中自定义了带参数的构造函数,编译不会生成默认的构造函数 // 如果没有默认的构造函数,则使用对象初始化时就会报错:没有实现 阅读全文
posted @ 2016-06-14 19:14 楊柳 阅读(215) 评论(0) 推荐(0) 编辑
摘要: String.Join Method (String, String[])用特定的分隔符连接数组元素 如:String.Join(sep, sArr) 阅读全文
posted @ 2016-06-14 13:17 楊柳 阅读(732) 评论(0) 推荐(0) 编辑
摘要: //// 摘要:// 使用一个指示调用线程是否应拥有互斥体的初始所属权的布尔值、一个作为互斥体名称的字符串,以及一个在方法返回时指示调用线程是否被授予互斥体的初始所属权的布尔值来初始化// System.Threading.Mutex 类的新实例。//// 参数:// initiallyOwned: 阅读全文
posted @ 2016-06-14 01:47 楊柳 阅读(1341) 评论(0) 推荐(0) 编辑
摘要: private void ExecuteJob(int hour = 10, int min = 10, int ss = 0) { ISchedulerFactory factory = new StdSchedulerFactory(); IScheduler scheduler = factory.GetScheduler(); scheduler.Start();... 阅读全文
posted @ 2016-06-13 18:17 楊柳 阅读(1169) 评论(0) 推荐(0) 编辑
摘要: 其他信息: CLR 无法从 COM 上下文 0x88e028 转换为 COM 上下文 0x88e0e0,这种状态已持续 60 秒。拥有目标上下文/单元的线程很有可能执行的是非泵式等待或者在不发送 Windows 消息的情况下处理一个运行时间非常长的操作。这种情况通常会影响到性能,甚至可能导致应用程序 阅读全文
posted @ 2016-06-13 18:14 楊柳 阅读(747) 评论(0) 推荐(0) 编辑
摘要: What is 'Context' on Android? Putting it simply: As the name suggests, it's the context of current state of the application/object. It lets newly-crea 阅读全文
posted @ 2016-06-13 18:06 楊柳 阅读(857) 评论(0) 推荐(0) 编辑
摘要: //首先要设置notifyIcon属性:Icon设置ico图标,否则在系统托盘无图标显示private void notifyIcon1_MouseDoubleClick(object sender, MouseEventArgs e) { this.WindowState = FormWindowState.Normal; //若使用Hide()时,要用Show()方法显示窗体... 阅读全文
posted @ 2016-06-13 16:52 楊柳 阅读(202) 评论(0) 推荐(0) 编辑
摘要: 1.每次变更都保存 2. 退出时保存 阅读全文
posted @ 2016-06-13 10:56 楊柳 阅读(334) 评论(0) 推荐(0) 编辑
摘要: .net内置的几个序列化器要求类型被标记SerializableAttribute,或者实现序列化接口,或者属性可读写且有无参数的构造函数,匿名类型并不符合这些条件。 阅读全文
posted @ 2016-06-12 21:49 楊柳 阅读(175) 评论(0) 推荐(0) 编辑
摘要: https://msdn.microsoft.com/en-us/library/ee388354(v=vs.110).aspx https://msdn.microsoft.com/en-us/library/system.web.httputility(v=vs.110).aspx (1) System.Web.HttpUtility 当进行Web请求时提供URL编码解码的方法,不能被继承... 阅读全文
posted @ 2016-06-12 21:45 楊柳 阅读(2128) 评论(0) 推荐(0) 编辑
摘要: function sleep(numberMillis){ var now=new Date(); var exitTime=now.getTime()+numberMillis; while(true){ now=new Date(); if(now.getTime()>exitTime){ re 阅读全文
posted @ 2016-06-12 16:29 楊柳 阅读(208) 评论(0) 推荐(0) 编辑
摘要: 1.字符串值中包含E等科学计数法,比如12E-2,需要进行转化为普通数值0.12, 2.转化函数如下: private Decimal ChangeDataToD(string strData) { Decimal dData = 0.0M; if (strData.Contains("E")) { 阅读全文
posted @ 2016-06-06 13:04 楊柳 阅读(16302) 评论(0) 推荐(1) 编辑