J2ME Class Not Found java/lang/ClassNotFoundException

来源:互联网 发布:js判断对象包含 编辑:程序博客网 时间:2024/05/12 07:36
 

when u r getting message like class not found it means from where ur application is being start that class is not access by the emulator and it is missing for it thats why such a error will generated.

when ur copying the whole folder in that folder one file with project properties also remain in the folder which has setting for class location.

but whenever u are creating the newer one this file is replace by new project property and ur setting is differ form newer one.

so you just go to setting menu>Midlet

there u will find midlet name, midlet icon, midlet classpath

you have to specify class path again in that loaction.

suppose your main midlet is in package Example and ur midlet class name is GameAction

then u have to specify same in midlet class name is

Example.Game Action.

i hope this will helps u.

Regards,

Jasmit vala

 

在网上找的的一段话,貌似是解决这个问题的方法,虽然我英语还不错,但是我也懒得看他,看了一下也不知道在讲什么,大概就是说模拟器找不到你的Class文件

出现问题的原因是你没有在描述器文件中定义你的MIDlet Suite中定义你的MIDlet

打开描述器,选择MIDlet选项(Define the Midlets that make up the Midlet Suite),把你的MIDlet添加进去。就行了,不懂我的意思,直接看图。

 

 

  

  jad文件就是描述器文件,打开它,选择下面选项卡的第二个的,添加你的MIDlet,就OK了

 

 

 

原创粉丝点击