原创 C# 壓縮目錄

保存目錄結構 ZipHelper幫助類 public class ZipHelper { public static readonly FastZip Instance = new FastZip() { Entry

原创 chrome headless抓網頁

index.js /* const { Chromeless } = require('chromeless'); async function run() { const chromeless = new Chromeles

原创 C# 獲取文件字符集

temp.csx //#! "netstandard2.0" #r "nuget:NChardet,1.0.1.6" #r "nuget:System.Text.Encoding.CodePages,4.5.0" #r "nuget:S

原创 chrome hsts設置

打開地址 chrome://net-internals/#hsts 點擊“Domain Security Policy” 在頁面下邊有個“Delete domain security policies” 輸入域名,點擊delete,查詢是

原创 csx調試C#代碼

.net 腳本csx,vscode新建一個csx文件,運行該文件可以直接打印輸出結果; 安裝:https://www.nuget.org/packages/dotnet-script/ dotnet tool install --glo

原创 記一次EF查詢返回無結果問題

按時間查詢,一開始是這麼寫的,咋看好像沒有問題;當開始時間和結束時間同時傳的時候,會發生什麼……………,查詢不到數據; 發生了什麼呢?!query生成的SQL,我拷貝出來,參數替換了,是有數據的,這個讓我折騰了很一會兒! DateTim

原创 DynamicExpresso表達式求值

DynamicExpresso 2.3.1 最低要求.net 4.6.1 github地址:https://github.com/davideicardi/DynamicExpresso 常用方法 /// <summary> /// 忽

原创 C#結構體比較

C#結構體是值類型,方法中傳參時是值的拷貝; 結構體定義: enum PointPosition { TopLeft, TopMiddle, TopRight } struct EdgePoint {

原创 .net core WebSocket

WebSocketMiddleware.csusing Microsoft.AspNetCore.Http; using System; using System.Collections.Concurrent; using System.

原创 ASP.NET可編輯下拉封裝

using System; using System.ComponentModel; using System.Web; using System.Web.UI; using System.Web.UI.HtmlControls; usi

原创 MVC Ajax複雜對象封裝

objectSerializer var objectSerializer = (function () { var objectSniffer = {}; objectSniffer.isArray = Fun

原创 js editabledropdown

pl.editabledropdown.css.editabledropdown { position: relative; display: inline-block; padd

原创 unable contact ip driver,error code 2

XP SP3 ping的時候報錯 解決方法: 1.運行輸入regedit,打開註冊表 刪除 HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Win

原创 Microsoft Web Platform Installer添加安裝源

1.下載Microsoft Web Platform Installer https://www.microsoft.com/web/downloads/platform.aspx 2.打開Microsoft Web Platform I

原创 WINCE 獲取第一個SD卡

API [DllImport("coredll", EntryPoint = "FindFirstStore")] public extern static IntPtr F