摘要: C#对磁盘IO操作的时候,经常会用到这些,路径,文件,文件名字,文件扩展名. 之前,经常用切割字符串来实现, 可是经常会弄错. 尤其是启始位置,多少个字节,经常弄晕. 下面这种方法貌似比较简便: string filePath = @"E:\Randy0528\中文目录\JustTes... 阅读全文
posted @ 2015-05-21 17:00 nieweiking 阅读(6781) 评论(0) 推荐(0) 编辑
摘要: 1.WMI简介WMI是英文WindowsManagementInstrumentation的简写,它的功能主要是:访问本地主机的一些信息和服务,可以管理远程计算机(当然你必须要拥有足够的权限),比如:重启,关机,关闭进程,创建进程等。2.使用时首先添加System.Management.dll,然后... 阅读全文
posted @ 2015-05-21 15:40 nieweiking 阅读(1687) 评论(0) 推荐(0) 编辑
摘要: UI界面: test1 后端代码:using System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Wind... 阅读全文
posted @ 2015-05-21 13:11 nieweiking 阅读(394) 评论(0) 推荐(0) 编辑
摘要: private void treeView1_SelectedItemChanged(object sender, RoutedPropertyChangedEventArgs e) { //节点(是子节点或者是根节点) TreeViewItem item = treeVi... 阅读全文
posted @ 2015-05-21 13:05 nieweiking 阅读(3899) 评论(0) 推荐(0) 编辑