I am running Windows 10.1803, build 17134.320. I am trying to get .asp files to open with VS Code. I went through the normal process, but no matter what, Windows would always ask me what program I wanted to use when I tried to open an ASP file.

So, I looked up the articles, and they said I basically had to edit the Windows registry manually. I can't find the article that I used as a reference, but it was a Microsoft doc. It said to have the file extension link to your program key, and then have your program key have the shell command, like so:

I did the same thing with .txt files and Sublime (because I had the same problem there), and it worked like a charm. But, for some reason, when I open an ASP file, Windows often edits the registry value for vscode. It becomes:

So, three changes. The default value of the root is added, a value of "Url Protocol" is added, and the command is modified. After this, opening a file in Windows explorer no longer works. If I edit the command back, it works again.

1 Answer
1

Found the solution here. I had created the custom registry key vscode, but Electron was editing it behind VS Code's back. I didn't notice that a key already existed named VSCodeSourceFile that was precisely what I needed. I remapped the .asp binding from vscode to VSCodeSourceFile, and this worked.