I have a program set up so I can double click a file in Explorer, or right click a file in Explorer and select open, and my application runs and opens the file (thanks to lots of code from this site).


I wonder if there's a way to do this with multiple files. You can select multiple files, right click and select Open, but they all open in a new instance of the program.


I can check for the App.PrevInstance and just not open files after the first one (to stop it from opening multiple instances), but I'd like to just open all the files in the first instance...


Or, if the app is already open and I double click a file in Explorer, I'd like it to open in the app instance that is running instead of opening a new instance...


Any ideas?


Thanks in advance for any help!