Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
New Contributor
Posts: 2
Registered: ‎12-26-2011
My Device: Blackberry 8100
My Carrier: Orange

Error preverifying class com.mypackage.MyClass - NoClassDefFoundError: java/lang/Object

I get the error mentioned in the heading when I run the following on a JAR file in a Windows terminal:

 

     $ preverify myfile.jar

 

The JAR file is an external MIDP JAR file developed in NetBeans. This worked fine on Windows 7 (32 bit), but now I get the error after reinstalling everything in Windows 7 (64 bit) running in VirtualBox on a Mac OS X host.

The JAR file that gets the error is the same file as before.

 

I have the same 32-bit java versions (1.6.0_32) in both installations (and no 64-bit Java installed), and the same BlackBerry WebWorks SDK 2.3.1.5.

 

JAVA_HOME and PATH are the same (apart from the (x86) in C:\Program Files (x86)).

 

PATH includes following:

 

C:\Program Files (x86)\Java\jdk1.6.0_32\bin;
C:\Program Files (x86)\Java\jre6\bin;
C:\Program Files (x86)\Research In Motion\BlackBerry WebWorks SDK 2.3.1.5\bin

 

The only difference I can find is that before I had
   eclipse\plugins\net.rim.ejde.componentpack7.1.0.7.1.0.4
and this is now
   net.rim.ejde.componentpack7.1.0.7.1.0.10
and the version of preverify.exe is newer. But copying the old preverify.exe and using that gives the same error.

 

New Contributor
Posts: 2
Registered: ‎12-26-2011
My Device: Blackberry 8100
My Carrier: Orange

Re: Error preverifying class com.mypackage.MyClass - NoClassDefFoundError: java/lang/Object

Solved it myself.

 

I missed a "classpath" parameter off the preverify command, and the parameter needed to be updated from "Program Files" to "Program Files (x86)"