03 2021 档案

摘要:1 xmlns:i="http://schemas.microsoft.com/xaml/behaviors" 2 3 4 <ListBox x:Name="peopleLbx" ItemsSource="{Binding PersonList}"> 5 <i:Interaction.Trigger 阅读全文
posted @ 2021-03-24 10:46 FredGrit 阅读(45) 评论(0) 推荐(0) 编辑
摘要:1 static void CallerDemo() 2 { 3 SystemRuntimeCompilerServicesCallerDemo("Test System.Runtime.CompilerServices.Caller"); 4 } 5 6 static void SystemRun 阅读全文
posted @ 2021-03-23 15:47 FredGrit 阅读(29) 评论(0) 推荐(0) 编辑
摘要:public MessageView() { InitializeComponent(); this.KeyDown += MessageView_KeyDown; } private void MessageView_KeyDown(object sender, KeyEventArgs e) { 阅读全文
posted @ 2021-03-23 11:33 FredGrit 阅读(51) 评论(0) 推荐(0) 编辑
摘要:1.Install-package Prism -v 4 2. 1 using Microsoft.Practices.Prism; 2 using Microsoft.Practices.Prism.Commands; 3 using Microsoft.Practices.Prism.Event 阅读全文
posted @ 2021-03-13 20:37 FredGrit 阅读(86) 评论(1) 推荐(0) 编辑
摘要:1 static void AnnoymousReflection() 2 { 3 var obj = new 4 { 5 First = 3456.345, 6 Second = 43545657, 7 Third = 'A', 8 Forth = "Test", 9 Fifth = true, 阅读全文
posted @ 2021-03-11 11:35 FredGrit 阅读(55) 评论(0) 推荐(0) 编辑
摘要:1 static void QuickSortDemo() 2 { 3 int[] arr = new int[] { 2, 5, -4, 11, 0, 18, 22, 67, 51, 6 }; 4 5 Console.WriteLine("Original array : "); 6 foreac 阅读全文
posted @ 2021-03-08 15:00 FredGrit 阅读(70) 评论(0) 推荐(0) 编辑
摘要:1.install-package system.text.json; 2. using System.Text.Json; using System.IO; 3. 1 static void SystemTextJsonDemo() 2 { 3 var obj = new[] 4 { 5 new 阅读全文
posted @ 2021-03-05 12:04 FredGrit 阅读(64) 评论(0) 推荐(0) 编辑
摘要: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 阅读(53) 评论(0) 推荐(0) 编辑
摘要:static void TestCallerMemberName() { CallerDemo("CallFilePath,CallerMemberName,CallerLineNumber"); } static void CallerDemo(string msg,[CallerFilePath 阅读全文
posted @ 2021-03-04 14:56 FredGrit 阅读(37) 评论(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 阅读(57) 评论(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 阅读(59) 评论(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 阅读(82) 评论(0) 推荐(0) 编辑

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