You can automatically attach the Visual Studio Just-In-Time debugger when a process is started on Windows. The steps are simple:
- Open the Registry Editor
- navigate to HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion\Image File Execution Options
- Select the application you want to debug:
- Either it already exists as subkey, then use that one
- Or, you have to create a new key in Image File Execution Options with the name of the application (e.g. chrome.exe)
- Create a new string value with name debugger and name vsjitdebugger.exe