上一页 1 ··· 93 94 95 96 97 98 99 100 101 ··· 123 下一页
摘要: 1 class Program 2 { 3 static void Main(string[] args) 4 { 5 EventDemo(); 6 Console.ReadLine(); 7 } 8 9 static void EventDemo() 10 { 11 MathClass mc = 阅读全文
posted @ 2021-03-05 11:22 FredGrit 阅读(62) 评论(0) 推荐(0)
摘要: static void TestCallerMemberName() { CallerDemo("CallFilePath,CallerMemberName,CallerLineNumber"); } static void CallerDemo(string msg,[CallerFilePath 阅读全文
posted @ 2021-03-04 14:56 FredGrit 阅读(46) 评论(0) 推荐(0)
摘要: static void PropertyPatternDemo() { string url = "https://devblogs.microsoft.com/dotnet/do-more-with-patterns-in-c-8-0/"; bool result = ShouldAllow(ne 阅读全文
posted @ 2021-03-03 11:27 FredGrit 阅读(69) 评论(0) 推荐(0)
摘要: 1.install-package System.Text.Json 2. static void SystemTextJsonJsonSerializerDemo() { var obj = new { Id = 1, Name = "Fred", Age = 34 }; string jsonV 阅读全文
posted @ 2021-03-03 09:14 FredGrit 阅读(70) 评论(0) 推荐(0)
摘要: The new feature is only available in C# 8 or greater,so add below statement in csproj file <LangVersion>8</LangVersion> <PropertyGroup> <Configuration 阅读全文
posted @ 2021-03-02 15:23 FredGrit 阅读(96) 评论(0) 推荐(0)
摘要: using System; using System.Collections.Generic; using System.IO; using System.Security.Cryptography; using System.Security.Principal; using System.Tex 阅读全文
posted @ 2021-02-08 10:41 FredGrit 阅读(77) 评论(0) 推荐(0)
摘要: static void M2ClassDemo() { M2Class m2 = new M2Class(10); m2.PrintTime(); } public class M2Class { static int M2Value=0; static readonly M2Class m2Obj 阅读全文
posted @ 2021-01-28 11:24 FredGrit 阅读(62) 评论(0) 推荐(0)
摘要: static void TestDictionaryInSensitive() { try { var comparer = StringComparer.OrdinalIgnoreCase; Dictionary<string, string> dic = new Dictionary<strin 阅读全文
posted @ 2021-01-27 11:06 FredGrit 阅读(103) 评论(0) 推荐(0)
摘要: alter table AdventureWorks2019.sales.SalesOrderDetail add IsValid bit not null constraint IsValid_Default_Constraint Default 1 with values; This will 阅读全文
posted @ 2020-12-03 22:18 FredGrit 阅读(293) 评论(0) 推荐(0)
摘要: xmlns:i="clr-namespace:System.Windows.Interactivity;assembly=System.Windows.Interactivity" xmlns:ii="http://schemas.microsoft.com/expression/2010/inte 阅读全文
posted @ 2020-12-02 17:13 FredGrit 阅读(120) 评论(0) 推荐(0)
上一页 1 ··· 93 94 95 96 97 98 99 100 101 ··· 123 下一页