Powershell不会将Java识别为cmdlet、函数、脚本文件或可操作程序的名称

Powershell不会将Java识别为cmdlet、函数、脚本文件或可操作程序的名称,java,powershell,Java,Powershell,我似乎无法使用任何java命令。我的机器上确实安装了java,我不知道从这里开始该怎么做。以下是我尝试打开java应用程序时出现的代码: java : The term 'java' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that

我似乎无法使用任何java命令。我的机器上确实安装了java,我不知道从这里开始该怎么做。以下是我尝试打开java应用程序时出现的代码:

java : The term 'java' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again. At line:1 char:1
+ java -Xmx7000m -jar \BaseX\BaseX.jar
+ ~~~~
    + CategoryInfo          : ObjectNotFound: (java:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

您需要将java添加到路径中


如果您在windows上,请搜索“编辑系统环境变量”。将路径添加到java/bin文件夹(如果安装了java,则应在程序文件中),并附加到变量名“path”下的变量值中。

您是否设置了
java
java\u HOME
系统变量?它是否从cmd.exe起作用?java.exe所在的目录是否在您的路径中?@TA我不知道如何找到它to@OcasoProtal不,在那里也不行。说明了一些关于java的信息,这些信息没有被识别为内部或外部命令。我也跟着你提到的那个帖子走了,被卡住了。