Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

how to open a folder by clicking a button in windows form application

Tags:

c#

winforms

How to open a folder by clicking a button in windows form application

I am developing a project in windows form application where I have created PDF file.By clicking a button, I want to open the folder of PDF file where I have saved it. so how can I do this?

N.B: I don't want to run any .exe file. I only want to open a folder.

like image 1000
Mohammad Aminul Islam Avatar asked Dec 28 '25 00:12

Mohammad Aminul Islam


1 Answers

This one should work

System.Diagnostics.Process.Start ("c:\\");

it opens the c drive in explorer for you

like image 167
Jones Joseph Avatar answered Dec 30 '25 16:12

Jones Joseph



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!