c#打开资源管理器

来源:互联网 发布:富二代的生活 知乎 编辑:程序博客网 时间:2024/06/05 17:24

winform点击按钮打开资源管理器,并定位到指定文件。

private void toolStripStatusLabel1_Click(object sender, EventArgs e)        {            System.Diagnostics.ProcessStartInfo psi = new System.Diagnostics.ProcessStartInfo("Explorer.exe");            psi.Arguments = "/e,/select," + path[i];            System.Diagnostics.Process.Start(psi);        }

其中path[i]为文件路径。