标签:c style class blog code java
1 /// <summary> 2 /// 浏览文件 3 /// </summary> 4 /// <param name="filePath"></param> 5 public static void ExploreFile(string filePath) 6 { 7 Process proc = new Process(); 8 proc.StartInfo.FileName = "explorer"; 9 //打开资源管理器 10 proc.StartInfo.Arguments = @"/select,"+filePath; 11 //选中"notepad.exe"这个程序,即记事本 12 proc.Start(); 13 } 14 15 /// <summary> 16 /// 浏览文件夹 17 /// </summary> 18 /// <param name="path"></param> 19 public static void ExplorePath(string path) 20 { 21 System.Diagnostics.Process.Start("explorer.exe", path); 22 }
C# 打开资源管理器浏览文件或文件夹,布布扣,bubuko.com
标签:c style class blog code java
原文地址:http://www.cnblogs.com/Johnfx-home/p/3770364.html