Microsoft KB Archive/225523

= PRB: JAVAH Cannot Find Classes When Executing =

Article ID: 225523

Article Last Modified on 2/24/2004

-

APPLIES TO


 * Microsoft Software Development Kit for Java 3.2
 * Microsoft Software Development Kit for Java 3.1

-



This article was previously published under Q225523



SYMPTOMS
When running Javah.exe on a Java class, you may get one of the following or similar errors:

Signalled error "java/lang/NoClassDefFoundError" with detail "java/io/Serializable"

-or-

java.lang.Object not found: aborting



CAUSE
Javah.exe, unlike the other Microsoft SDK for Java tools, requires the user to specify a class path via the "-classpath" command line option or via the CLASSPATH environment variable. If the class path is not specified, is invalid, or contains corrupted or missing data, then Javah.exe does not work.



RESOLUTION
There are a couple of things to check if you receive one of these error message:

  Verify that the CLASSPATH environment variable or the "-classpath" command line option points to [windir]\java\classes\Classes.zip and the directory that contains your class files.   Open Classes.zip and verify that the class specified in the error message is contained within. If Classes.zip is corrupt or if the specified class is missing, run the following from a DOS command prompt to regenerate a new Classes.zip file: clspack -auto 



STATUS
This behavior is by design.

Additional query words: JAVAH.EXE JAVAH

Keywords: kbjnative kbprb KB225523

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.