How in c# can I make a file open with a specified program ie: not the default program for that file type
If you can build a command-line to run the program (including passing the input file as a command-line parameter) than build the command line ans use Process.Start
.
Of course this assumes
How 2. works depends on the program. It could be as simple as
Process.Start("MyProgram.exe","MyFile.dat")
But other programs may require a command-line switch or other information.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With