【发布时间】:2012-03-15 14:50:35
【问题描述】:
我在 NetBeans 7.1 中使用 j2me SDK 3.0 和 3.0.5 制作了一个 j2me 应用程序。几天前,在不影响启动的代码进行重大更改之前,它运行良好。现在尝试运行应用程序时,它会启动模拟器,但无法启动应用程序。输出显示如下:
Starting emulator in execution mode
Installing suite from: http://127.0.0.1:16200/BuitenBeter.jad
Processing UPDATE_CLASS
关闭模拟器后提示如下错误:
*** Error ***
Failed to execute MIDlet suite
C:\Users\Willem\Documents\NetBeansProjects\BuitenBeter\nbproject\build-impl.xml:782: Execution failed with error code 1.
BUILD FAILED (total time: 1 minute 16 seconds)
它指向的xml是:
<!--cldc-run-->
<target name="cldc-run" if="cldc-platform.trigger">
<nb-run jadfile="${dist.dir}/${dist.jad}" jarfile="${dist.dir}/${dist.jar}" jadurl="${dist.jad.url}" device="${platform.device}" platformhome="${platform.home}" platformtype="${platform.type}" execmethod="${run.method}" securitydomain="${evaluated.run.security.domain}" commandline="${platform.runcommandline}" classpath="${platform.bootclasspath}:${dist.dir}/${dist.jar}" cmdoptions="${run.cmd.options}"/>
</target>
所以我假设 CLDC 无法运行。
当我创建一个只包含“Hello World”代码的空新项目时,它在相同的配置下运行良好。即:
- j2me SDK 3.0.5
- DefaultCldcPhone1
- CLDC-1.1
- MIDP-2.0
- 已选择所有可选包
我尝试过使用 SDK 3.0,我尝试过不使用所有可选包,我尝试过使用 CLDC-1.1.1。 But when selecting CLDC-1.1.1 it automaticly does the following:
Platform UEI-1.0.1 does not support "CLDC-1.1.1" configuration, setting back to CLDC-1.1.
到目前为止,谷歌搜索后我已经尝试了以下解决方案:
- 只需重新启动 NetBeans
- 停止 Windows 防火墙
- 使用不同的设备和配置
谁能告诉我出了什么问题或者我可以做些什么来解决这个问题?
【问题讨论】:
-
你解决了吗?我在使用默认演示项目时遇到了同样的问题:HelloMidlet.java
-
@Memochipan 不,我通过将项目导入 J2ME SKD 3.0 中找到了解决方法,该项目仍在我的笔记本电脑上运行。这不是一个解决方案,但它有效:)