3

When install vs code from exe, we can chose the option to add "Open with vs code" to right click menu: enter image description here

However, when install vs code via Microsoft Store, there is no step to config it.

How to add "Open with vs code", when install vs code via Microsoft Store, instead of download .exe?

Marcus Wong
  • 341
  • 3
  • 15

3 Answers3

3

It seems not possible out of the box, but there is a feature request for it at https://github.com/microsoft/vscode/issues/134470

hansmbakker
  • 1,108
  • 14
  • 29
0

Follow the instructions given in here:

How to open your files with vs code from the context menu on Windows

This is a workaround solution, Create a .reg file and run it.

Worked for me.

spiders.here
  • 127
  • 2
  • 13
0

create a .reg file with the following:

Windows Registry Editor Version 5.00 ; Open files [HKEY_CLASSES_ROOT*\shell\Open with VS Code] @="Edit with VS Code" "Icon"="%LocalAppData%\Programs\Microsoft VS Code\Code.exe,0" [HKEY_CLASSES_ROOT*\shell\Open with VS Code\command] @=hex(2):22,00,25,00,4c,00,6f,00,63,00,61,00,6c,00,41,00,70,00,70,00,44,00,61,
00,74,00,61,00,25,00,5c,00,50,00,72,00,6f,00,67,00,72,00,61,00,6d,00,73,00,
5c,00,4d,00,69,00,63,00,72,00,6f,00,73,00,6f,00,66,00,74,00,20,00,56,00,53,
00,20,00,43,00,6f,00,64,00,65,00,5c,00,43,00,6f,00,64,00,65,00,2e,00,65,00,
78,00,65,00,22,00,20,00,22,00,25,00,56,00,22,00,00,00 ; This will make it appear when you right click ON a folder ; The "Icon" line can be removed if you don't want the icon to appear [HKEY_CLASSES_ROOT\Directory\shell\vscode] @="Open Folder in Code" "Icon"=""%LocalAppData%\Programs\Microsoft VS Code\Code.exe",0" [HKEY_CLASSES_ROOT\Directory\shell\vscode\command] @=""%LocalAppData%\Programs\Microsoft VS Code\Code.exe" "%1"" ; This will make it appear when you right click INSIDE a folder ; The "Icon" line can be removed if you don't want the icon to appear [HKEY_CLASSES_ROOT\Directory\Background\shell\vscode] @="Open Folder in Code" "Icon"=""%LocalAppData%\Programs\Microsoft VS Code\Code.exe",0" [HKEY_CLASSES_ROOT\Directory\Background\shell\vscode\command] @=hex(2):22,00,25,00,4c,00,6f,00,63,00,61,00,6c,00,41,00,70,00,70,00,44,00,61,
00,74,00,61,00,25,00,5c,00,50,00,72,00,6f,00,67,00,72,00,61,00,6d,00,73,00,
5c,00,4d,00,69,00,63,00,72,00,6f,00,73,00,6f,00,66,00,74,00,20,00,56,00,53,
00,20,00,43,00,6f,00,64,00,65,00,5c,00,43,00,6f,00,64,00,65,00,2e,00,65,00,
78,00,65,00,22,00,20,00,22,00,25,00,56,00,22,00,00,00

  • As it’s currently written, your answer is unclear. Please [edit] to add additional details that will help others understand how this addresses the question asked. You can find more information on how to write good answers [in the help center](/help/how-to-answer). – Community Dec 19 '22 at 12:28