“代码”。命令在命令提示符下不起作用 [英] "code ." command is not working in command prompt

查看:95
本文介绍了“代码”。命令在命令提示符下不起作用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在使用angular cli创建了角度应用程序之后,我尝试使用 code在Visual Studio代码中打开解决方案。从命令提示符下输入命令,但显示以下错误。有什么建议吗?

After creating angular application using angular cli, I tried to open the solution in visual studio code using "code ." command from command prompt, but it shows below error. Any suggestion?

推荐答案

假设您正在使用Windows,请确保在环境变量 Path 中声明了 vscode bin文件夹。无论是用户还是系统都可以,但是,我建议对系统变量进行声明,因此它对所有用户均可用。

Provided that you are using Windows, make sure your vscode bin folder is declared on your Environment Variable Path. Either user or system will do but, I recommend declaring on System Variables therefore it's available for all users.

Visual Studio代码通常安装在以下目录中,具体取决于您的安装建筑。在您的路径中声明其中一个,它应该已经可用。

Visual studio code usually is installed on the following directories depending on your installation architecture. Declare one of those on your Path and it should be available already.

x86

C:\Program Files (x86)\Microsoft VS Code\bin

x64

C:\Program Files\Microsoft VS Code\bin




警告:的旧版本Windows需要您重新启动操作系统才能有效地更改环境变量。

Warning: Older versions of Windows requires you to restart the operating system in order to change environment variables effectively.

这篇关于“代码”。命令在命令提示符下不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆