随笔分类 -  C#实用技巧

C#编程中实用的代码与技巧
摘要:1、名字空间 using System.Runtime.InteropServices; 2、API函数申明 [DllImport("user32.dll", CharSet = CharSet.Auto, ExactSpelling = true)] public static extern In 阅读全文
posted @ 2020-02-04 14:18 编码的奥秘 阅读(592) 评论(0) 推荐(0)
摘要:public Form1() { InitializeComponent(); //桌面窗口区宽减自身宽,高减自身高 int x = System.Windows.Forms.Screen.PrimaryScreen.WorkingArea.Size.Width - this.Size.Width; 阅读全文
posted @ 2020-02-04 13:54 编码的奥秘 阅读(316) 评论(0) 推荐(0)