无法将"appletviewer"识别为内部或外部命令,可操作程序或批处理文件 [英] 'appletviewer' is not recognized as an internal or external command, operable program or batch file
问题描述
C:\ Users \ ms536 \ Desktop \ java> appletviewer awt_ex.java 无法将"appletviewer"识别为内部或外部命令, 可操作的程序或批处理文件.
C:\Users\ms536\Desktop\java>appletviewer awt_ex.java 'appletviewer' is not recognized as an internal or external command, operable program or batch file.
推荐答案
我可以想到三种可能的解释:
I can think of three possible explanations for this:
-
您可能没有正确设置命令搜索路径(
$PATH
).这对Java初学者来说是很普遍的.请参阅 javac不被识别为内部或外部命令,可操作程序或批处理文件
You may have not set the command search path (
$PATH
) correctly. This is a common for people who are new to Java; see javac is not recognized as an internal or external command, operable program or batch file
您可能正在尝试在Java 11或更高版本中使用appletviewer
.这行不通.在Java 9中不赞成使用Applet,而在Java 11中则完全删除了该支持.参见 https://bugs.java.com/bugdatabase/view_bug.do? bug_id = JDK-8200146 .
You may be trying to use appletviewer
in Java 11 or later. This won't work. Applet support was deprecated in Java 9, and was removed entirely in Java 11; see https://bugs.java.com/bugdatabase/view_bug.do?bug_id=JDK-8200146.
您可能已经安装了JRE而不是JDK. appletviewer
仅在JDK安装中可用.
You may have installed a JRE rather than a JDK. The appletviewer
is (was) only available in JDK installations.
这篇关于无法将"appletviewer"识别为内部或外部命令,可操作程序或批处理文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!