开发者

How to open a particular directory and SELECT a particular file there using C#

开发者 https://www.devze.com 2023-03-02 08:32 出处:网络
In my existing program, after completing some result I store it in a file. I have the file(folder) path saved in a string var,

In my existing program, after completing some result I store it in a file.

I have the file(folder) path saved in a string var,

I am seeking a way to open the same folder (not file directly) and in that explorer window, particular file must be selected!

so that user开发者_运维问答 can come to know which file has been created by the code.


This is what you are looking for.

You pass explorer.exe /select, filename

Opening a folder in explorer and selecting a file

Here are some more command line options for explorer.exe


And also look in to Process.Start Method.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号