Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

simple code builds but doesn't run :(

 
Fernando Sanz
Ranch Hand
Posts: 101
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi, yesterday I installed the J2ME Wireless Toolkit at Uni. I tried a couple of simple programs and they worked.
Now, I'm trying to run the same ones at my computer, and eventhough they BUILD proplerly, when I RUN them, this is what I get on the J2WT screen:
Creating project "first"
Place Java source files in "C:\WTK20\apps\first\src"
Place Application resource files in "C:\WTK20\apps\first\res"
Place Application library files in "C:\WTK20\apps\first\lib"
Project settings saved
Building "first"
Build complete
Running with storage root DefaultColorPhone
Unable to create MIDlet FirstMIDlet.java
java.lang.ClassNotFoundException: FirstMIDlet.java
at com.sun.midp.midlet.MIDletState.createMIDlet(+14)
at com.sun.midp.midlet.Selector.run(+22)
Execution completed successfully
363629 bytecodes executed
21 thread switches
430 classes in the system (including system classes)
1977 dynamic objects allocated (63836 bytes)
1 garbage collections (0 bytes collected)

anyone knows what I'm doing wrong?
thanks
 
Fernando Sanz
Ranch Hand
Posts: 101
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Oops, my fault, I found out my mistake. When I started the project, I had to write a name for the project itself and for the MIDlet class name.
When I wrote the MIDlet name, I included the extension .java (don't ask me why).
Now it's up and running
let's keep on coding....
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic