vscode安装后,右键选择文件夹没有vscode打开选项,该怎么解决

我现在的电脑安装的是win11,就遇到一个奇怪的问题。vscode安装也没问题,但是右键看不到vscode的选项。
0f4768db-4ceb-4a6b-8271-6e176dbeb457
操作步骤如下:
1,操作前先打开windows安全中心,打开病毒与防护
b385c0e8-b450-46d6-be62-925b4bae2b00
2,打开病毒和威胁防护设置的 管理设置
27768977-d794-463f-a311-621b19a7999e
3,防篡改设置要关闭
16e8b423-5281-4208-b3a2-98244b8a6cbf
注意:下面注册表运行完毕后,再开启

4,cmd--where code 确定vscode的安装位置
5,创建一个txt文档,把下面的文件复制进去
Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\Directory\shell\Open with Code]
@="Open with Code"
"Icon"="D:\vscode_soft\Microsoft VS Code\Code.exe,0"

[HKEY_CLASSES_ROOT\Directory\shell\Open with Code\command]
@=""D:\vscode_soft\Microsoft VS Code\Code.exe" "%1""

[HKEY_CLASSES_ROOT\Directory\Background\shell\Open with Code]
@="Open with Code"
"Icon"="D:\vscode_soft\Microsoft VS Code\Code.exe,0"

[HKEY_CLASSES_ROOT\Directory\Background\shell\Open with Code\command]
@=""D:\vscode_soft\Microsoft VS Code\Code.exe" "%V""

[HKEY_CLASSES_ROOT*\shell\Open with Code]
@="Open with Code"
"Icon"="D:\vscode_soft\Microsoft VS Code\Code.exe,0"

[HKEY_CLASSES_ROOT*\shell\Open with Code\command]
@=""D:\vscode_soft\Microsoft VS Code\Code.exe" "%1""
6. 我的文件路径在D盘的vscode文件夹,把这个文件更名为 vscode右键.reg 双击 运行即可,你的文件路径,以你的为准,最好和我的一样

posted on 2026-10-08 20:11  一起疯狂  阅读(19)  评论(0)    收藏  举报

导航