摘要: 什么是委托? 将一个方法作为参数传递给另一个方法。 注意:委托所指向的方法必须和委托具有相同的签名(返回值类型和参数列表) 举例 using System; using System.Collections.Generic; using System.Linq; using System.Text; 阅读全文
posted @ 2020-05-28 23:33 兔子不会吃草 阅读(173) 评论(0) 推荐(0) 编辑
摘要: 为什么要用多线程 让计算机"同时"做多件事情,节约时间。 多线程可以让一个程序“同时”处理多个事情。 后台运行程序,提高程序的运行效率,也不会使主界面出现无响应的情况。 获得当前线程和当前进程 如何实现多线程? 编写产生线程所要执行的方法 引用System.Threading命名空间 实例化Thre 阅读全文
posted @ 2020-05-28 17:42 兔子不会吃草 阅读(117) 评论(0) 推荐(0) 编辑
摘要: 进程 我们可以把计算机中每一个运行的应用程序都当做是一个进程。 而一个进程又是由多个线程组成的。 Process GetProcesses():获得当前程序中所有正在运行的进程 Process[] pros = Process.GetProcesses(); foreach (var item in 阅读全文
posted @ 2020-05-27 23:18 兔子不会吃草 阅读(138) 评论(0) 推荐(0) 编辑
摘要: 效果 实现 代码 using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; usin 阅读全文
posted @ 2020-05-27 21:58 兔子不会吃草 阅读(1508) 评论(0) 推荐(0) 编辑
摘要: 效果 #实现 代码 using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; usi 阅读全文
posted @ 2020-05-27 21:31 兔子不会吃草 阅读(206) 评论(0) 推荐(0) 编辑
摘要: 效果 实现 代码 using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.IO; using 阅读全文
posted @ 2020-05-27 21:07 兔子不会吃草 阅读(205) 评论(0) 推荐(0) 编辑
摘要: 效果 实现 代码 using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.IO; using 阅读全文
posted @ 2020-05-27 19:53 兔子不会吃草 阅读(1058) 评论(0) 推荐(0) 编辑
摘要: 效果 实现 代码 using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace WindowsFormsApp 阅读全文
posted @ 2020-05-27 18:38 兔子不会吃草 阅读(314) 评论(0) 推荐(0) 编辑
摘要: Directory 用于操作文件夹 方法 CreateDirectory():创建文件夹 Directory.CreateDirectory(@"D:\a"); Delete():删除文件夹 Directory.Delete(@"D:\a",true); Move():剪切文件夹 Directory 阅读全文
posted @ 2020-05-27 14:32 兔子不会吃草 阅读(174) 评论(0) 推荐(0) 编辑
摘要: 效果图 实现 代码 using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; usi 阅读全文
posted @ 2020-05-26 21:41 兔子不会吃草 阅读(269) 评论(0) 推荐(0) 编辑