Hey all, I am having an issue with a NOClassDefFoundError. I am new to creating MIDlets so I am working with a textbook, Kicking Butt With MIDP and MSA and I think it's the most recent edition… not sure. At any rate I am working with the section on push registry and I've tried to compile and run the example in the text… it compiles fine, but I get a runtime error telling me that the PushRegistry class is not defined at javax.microeditoin.io.PushRegistry… ??? I've checked the JME API and as sure as the sun shines the class is defined in that package… therefore I am confused and frustrated.
If the class wasn't defined within the package shouldn't that be caught at compilation time instead of at runtime? I think that is the case so there must be something else going on that I'm not aware of... can anyone help me out with this? I'm really tired of wasting my time trying to make things do what they were intended to do instead of actually coding.
I am using NetBeans 7.1 and MPowerPlayer 2.0.1185 for my Emulator. The Error occurs at runtime immediately after the emulator is started…
here is the relevant bit of the error message…
Copying 1 file to /Users/JohnDoe/NetBeansProjects/PushRegistryExample/dist/nbrun4958300352654849687
Copying 1 file to /Users/JohnDoe/NetBeansProjects/PushRegistryExample/dist/nbrun4958300352654849687
Jad URL for OTA execution: http://localhost:8082/servlet/org.netbeans.modules.mobility.project.jam.JAMServlet//Users/rohanharrison/NetBeansProjects/PushRegistryExample/dist//PushRegistryExample.jad
Starting emulator in execution mode
mpowerplayer 2.0.1185
Error while starting midlet:
java.lang.NoClassDefFoundError: javax/microedition/io/PushRegistry
at PushyMIDlet.startApp(PushyMIDlet.java:41)
at javax.microedition.midlet.MIDlet._startApp(MIDlet.java:89)
at com.mpp.adapter.Controller._start(Controller.java:867)
at com.mpp.adapter.Controller.access$100(Controller.java:98)
at com.mpp.adapter.Controller$3.run(Controller.java:831)
at java.lang.Thread.run(Thread.java:655)
Could it be the emulator I'm using?