原创 同步異步 生產者/消費者

namespace Test { class Program { private static readonly BlockingCollection<int> ts = new System.Coll

原创 鼠標右鍵選中行

 轉自:https://www.cnblogs.com/dekevin/p/3626944.html 事件是  CellButtonDown private void HandleCellMouseDown(object sender,

原创 多線程中的同步 ,鎖資源

// This example shows how a Mutex is used to synchronize access // to a protected resource. Unlike Monitor, Mutex can

原创 異步 併發 async

當時面試時遇到異步與線程的關係,當時的知識量是 1, 一個線程執行一個任務  2. 遇到異步之後交回控制權,3.那麼推理異步函數是由其他線程執行(線程池中)。 不知道當時的面試官他自己有沒有清楚這個是怎麼運行的,感覺他就是蒙的 測試如下:

原创 存儲過程

https://www.jianshu.com/p/abab22348e55   if(exists(select * from sys.objects where name= 'task_insert' )) drop proc

原创 socket 一些基礎類

IPAddress ipAddress=Dns.Resole("localhost").AddressList[0]; IPAddress i=IPAddress.Parse("127.0.0.1"); IPAddress.Parse

原创 winform 訪問web service

 winform 端調用 using Newtonsoft.Json; using System; using System.Collections; using System.Collections.Generic; using Sy

原创 SetBuffer socket

Examples The following code example creates a single large buffer which can be divided up and assigned to SocketAsync

原创 web service 代理

https://www.cnblogs.com/dengxinglin/p/3333531.html wsdl.exe /l:cs /out:D:\Proxcy_AGVDispatchService.cs http://localhos

原创 hashtable 轉 json

zhuan:https://www.cnblogs.com/sntetwt/p/3500740.html 代碼如下: ArrayList eventList = new ArrayList();

原创 sql 大全

原文鏈接:https://www.cnblogs.com/1234abcd/p/5530314.html  轉自:https://www.cnblogs.com/1234abcd/p/553

原创 sql 漢字簡單排序

但是因爲在數據庫中存儲順序問題  出來的結果是    SQL code? 1 2 3 用電二隊 用電三隊 用電一隊   select distinct area_name from area_addr_info order by

原创 左鏈接與子查詢效率比較

經測試 左鏈接的效率要高很多,子查詢要建臨時表  測試轉自https://bbs.csdn.net/topics/391030135?page=1 create table A (id char(10),fname varchar(20

原创 sql 一層層傳參,數據來源,與下拉列表加入數據庫的值

新增,更新時頁面傳參:PMTemplateID#{[ID]};          SubClasses#{[SubClasses]};     更新:                 篩選條件:IsDel=0 and PMTemplate

原创 web api 學習過程總結

1.  特性           [Produces("application/json")] public class AuthorsController   [FormatFilter] public class ProductsCo