11 2019 档案

摘要:static void GetNetVersionDemo() { using (RegistryKey ndpKey = RegistryKey.OpenBaseKey(RegistryHive.LocalMachine, RegistryView.Registry32).OpenSubKey(@"SOFTWARE\Microsoft\NET Fr... 阅读全文
posted @ 2019-11-28 22:35 FredGrit 阅读(303) 评论(0) 推荐(0) 编辑
摘要:using System.Reflection; static void ShowEnvironmentInfoDemo() { Type type = typeof(Environment); PropertyInfo[] pis = type.GetProperties(); if (pis != nu... 阅读全文
posted @ 2019-11-27 22:38 FredGrit 阅读(243) 评论(0) 推荐(0) 编辑
摘要:private void ClickCmdExecuted(object obj) { ContentOb = new ObservableCollection<string>(); Task.Run(() => { while (!cts.IsCancellationRequested) { Co 阅读全文
posted @ 2019-11-27 22:21 FredGrit 阅读(972) 评论(0) 推荐(0) 编辑
摘要:using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Net.Sockets; using System.IO; using System.Net; namespace ConsoleApp3... 阅读全文
posted @ 2019-11-25 13:21 FredGrit 阅读(445) 评论(0) 推荐(0) 编辑
摘要:using System; using System.Collections.Generic; using System.ComponentModel; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Windows; namespace WpfApp55.ViewModel { ... 阅读全文
posted @ 2019-11-24 17:02 FredGrit 阅读(472) 评论(0) 推荐(0) 编辑
摘要:using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading; using System.Threading.Tasks; namespace ConsoleApp393 { class Program { ... 阅读全文
posted @ 2019-11-24 15:51 FredGrit 阅读(263) 评论(0) 推荐(0) 编辑
摘要:using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Diagnostics; using System.Net; using System.IO; using System.Windows.Fo 阅读全文
posted @ 2019-11-23 21:26 FredGrit 阅读(228) 评论(0) 推荐(0) 编辑
摘要:using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Diagnostics; namespace ConsoleApp392 { class Program { static void Main 阅读全文
posted @ 2019-11-23 20:19 FredGrit 阅读(216) 评论(0) 推荐(0) 编辑
摘要:I had validated in .net 4.8 NewtonSoft.Json's speed rank 1st,System.Text.Json.JsonSerializer.Serialize 2nd,and BinaryFormatter 3rd. 阅读全文
posted @ 2019-11-23 19:01 FredGrit 阅读(345) 评论(0) 推荐(0) 编辑
摘要:using System;using System.Collections.Generic;using System.Collections;using System.IO;using System.Runtime.Serialization.Formatters.Binary;using Syst 阅读全文
posted @ 2019-11-22 12:03 FredGrit 阅读(400) 评论(0) 推荐(0) 编辑
摘要:static void Main(string[] args) { string dir = @"C:\"; string[] dirs=Directory.GetDirectories(dir); long totalSize = 0; if(dirs!=null && di... 阅读全文
posted @ 2019-11-21 20:16 FredGrit 阅读(296) 评论(0) 推荐(0) 编辑
摘要:static void RenameFiles() { string sourceDir = @"D:\ll"; string[] allFiles = Directory.GetFiles(sourceDir, "*.mp3", SearchOption.AllDirectories); if(allFi... 阅读全文
posted @ 2019-11-21 13:43 FredGrit 阅读(209) 评论(0) 推荐(0) 编辑
摘要:static void CopyFiles() { string sourceDir = @"D:\C\ll"; string destDir = @"D:\LL"; if (!Directory.Exists(destDir)) { Directo... 阅读全文
posted @ 2019-11-21 12:12 FredGrit 阅读(291) 评论(0) 推荐(0) 编辑
摘要:class Program { static void Main(string[] args) { Thermostat thermostat = new Thermostat(); Heater heater = new Heater(60); Cooler cooler = ne... 阅读全文
posted @ 2019-11-20 20:02 FredGrit 阅读(163) 评论(0) 推荐(0) 编辑
摘要:1.Install-Package StackExchange -v 2.0.601 2.using StackExchange.Redis; 3. 阅读全文
posted @ 2019-11-19 21:32 FredGrit 阅读(214) 评论(0) 推荐(0) 编辑
摘要:1. Install-package naudio -v 1.9.0 2. using NAudio.Wave; 3. 阅读全文
posted @ 2019-11-19 18:43 FredGrit 阅读(219) 评论(0) 推荐(0) 编辑
摘要:using System; using System.Collections.Generic; using System.Linq; using System.Runtime.Serialization; using System.Text; using System.Threading.Tasks; namespace ConsoleApp386 { class Program { static 阅读全文
posted @ 2019-11-19 11:29 FredGrit 阅读(270) 评论(0) 推荐(0) 编辑
摘要:static void Main(string[] args) { WebRequestDemoAsync(); Console.ReadLine(); } static async void WebRequestDemoAsync() { string url = "https://docs.mi 阅读全文
posted @ 2019-11-12 17:18 FredGrit 阅读(265) 评论(0) 推荐(0) 编辑
摘要:static void MutexDemo2() { string assName = Assembly.GetEntryAssembly().FullName; bool createdNew; using (var mutex = new Mutex(false, assName, out createdNew)) { if (!createdNew) { Console.WriteLine( 阅读全文
posted @ 2019-11-11 13:33 FredGrit 阅读(263) 评论(0) 推荐(0) 编辑
摘要:I had validated this.To download SSMS which is more than 500M+ static void Main(string[] args) { string url = "https://go.microsoft.com/fwlink/?linkid=2108895&amp;clcid=0x409"; DownloadBigFile(new Uri 阅读全文
posted @ 2019-11-10 14:02 FredGrit 阅读(432) 评论(0) 推荐(0) 编辑
摘要:static void Main(string[] args) { Task firstTask = Task.Run(() => { PrintPlus(); }); Task secondTask = firstTask.C... 阅读全文
posted @ 2019-11-09 21:09 FredGrit 阅读(1108) 评论(0) 推荐(0) 编辑
摘要:1 using System.Windows.Media; 2 using Newtonsoft.Json; 3 using System.ComponentModel; 4 5 namespace ConsoleApp378 6 { 7 class Program:INotifyPropertyChanged 8 { 9 s... 阅读全文
posted @ 2019-11-02 20:58 FredGrit 阅读(411) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示