Eclipse运行错误 [英] Eclipse run error

查看:285
本文介绍了Eclipse运行错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我尝试在Eclipse上运行我的代码时,会出现以下错误:



 
用法:javaw [-options] class [ args ...]
(执行一个类)
或javaw [-options] -jar jarfile [args ...]
(执行一个jar文件)
其中选项包括:
-d32使用32位数据模型(如果可用)
-d64使用64位数据模型(如果可用)
-server选择服务器VM
-hotspot是服务器VM的同义词[已弃用]
默认的VM是服务器。



-cp< class search path of目录和zip / jar文件>
-classpath<目录和zip / jar文件的类搜索路径>
A;目录分离列表,JAR存档,
和ZIP存档来搜索类文件。
-D< name> =< value>
设置系统属性
-verbose:[class | gc | jni]
启用详细输出
-version打印产品版本并退出
-version:< value> ;
要求指定的版本运行
-showversion打印产品版本并继续
-jre-restrict-search | -no-jre-restrict-search
在版本搜索中包含/排除用户私有JRE
- ? -help打印此帮助消息
-X在非标准选项上打印帮助
-ea [:< packagename> ... |:< classname>]
-enableassertions [:< ; packagename> ... |:< classname>]
启用具有指定粒度的断言
-da [:< packagename> ... |:< classname>]
-disableassertions [:< packagename> ... |:< classname>]
禁用具有指定粒度的断言
-esa | -enablesystemassertions
启用系统断言
-dsa | -disablesystemassertions
禁用系统断言
-agentlib:< libname> [=< options>]
加载本机代理库< libname> -agentlib:hprof
另请参见:-agentlib:jdwp = help和-agentlib:hprof = help
-agentpath:< pathname> [=< options>]
加载本机代理库通过完整路径名
-javaagent:< jarpath> [=< options>]
加载Java编程语言代理,请参阅java.lang.instrument
-splash:< imagepath>
显示具有指定图像的初始屏幕
有关详细信息,请参阅http://www.oracle.com/technetwork/java/javase/documentation/index.html。



代码,这个错误仍然出现。

解决方案

似乎你没有正确设置你的java路径。
$ b

使用Java设置Eclipse 1.6在Windows上



如何安装并开始使用Java编程


When i try to run my code on Eclipse this error appears:

Usage: javaw [-options] class [args...]
           (to execute a class)
   or  javaw [-options] -jar jarfile [args...]
           (to execute a jar file)
where options include:
    -d32      use a 32-bit data model if available
    -d64      use a 64-bit data model if available
    -server   to select the "server" VM
    -hotspot      is a synonym for the "server" VM  [deprecated]
                  The default VM is server.

-cp <class search path of directories and zip/jar files> -classpath <class search path of directories and zip/jar files> A ; separated list of directories, JAR archives, and ZIP archives to search for class files. -D<name>=<value> set a system property -verbose:[class|gc|jni] enable verbose output -version print product version and exit -version:<value> require the specified version to run -showversion print product version and continue -jre-restrict-search | -no-jre-restrict-search include/exclude user private JREs in the version search -? -help print this help message -X print help on non-standard options -ea[:<packagename>...|:<classname>] -enableassertions[:<packagename>...|:<classname>] enable assertions with specified granularity -da[:<packagename>...|:<classname>] -disableassertions[:<packagename>...|:<classname>] disable assertions with specified granularity -esa | -enablesystemassertions enable system assertions -dsa | -disablesystemassertions disable system assertions -agentlib:<libname>[=<options>] load native agent library <libname>, e.g. -agentlib:hprof see also, -agentlib:jdwp=help and -agentlib:hprof=help -agentpath:<pathname>[=<options>] load native agent library by full pathname -javaagent:<jarpath>[=<options>] load Java programming language agent, see java.lang.instrument -splash:<imagepath> show splash screen with specified image See http://www.oracle.com/technetwork/java/javase/documentation/index.html for more details.

i try to coment my entired code and this error still appear.

解决方案

It seems you haven't set your java path correctly.

Setting Up Eclipse with Java 1.6 on Windows

How To Install and Get Started with Java Programming

这篇关于Eclipse运行错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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