Well, I can't tell what your problem is from the general descriptions you have given. But the following link gives instructions on how to configure Windows so that whenever your application is launched it will be automatically run under the Visual Studio debugger.
Can I open a file from my file explorer and have it run my Visual Studio solution?

Trevor Youngman
1
Reputation point
Hello,
There is a bug in my app that only occurs when the app is started from the file explorer (double-clicking a file to open the app and file within the app)
Is there a way to have my Visual Studio solution run when opening from the file explorer?
I tried attaching the file explorer process to my app in debug but that did not seem to work, or I did not do that correctly.
Thanks.
{count} votes
Yes I believe your understanding is correct.
The app is written in C#, and I am using Visual Studio 2017.
I have not tried your last suggestion, but to be more specific, the problem is occurring because the app cannot locate another required file when starting the app from the file explorer. If the app is already running and the file is attempted to be opened, I have a warning appear letting the user know that they need to add the file to their dependencies...
This question is more to ensure that the changes I have made to solve the problem are working correctly, and if what I am trying to do (using my solution when double-clicking an associated file in file explorer) is even possible