I imported this morning following JAVA-Libary to my Android-Project: JSON-Libary I imported it over Project->Properties ->Add external Jar files.
After that I wrote my code with which I use this Libary, but I get this Error ouf of LogCat:
11-24 13:20:04.371: W/dalvikvm(29450): Unable to resolve superclass of Lnet/sf/json/JSONException; (420)
11-24 13:20:04.371: W/dalvikvm(29450): Link of class 'Lnet/sf/json/JSONException;' failed
11-24 13:20:04.381: W/dalvikvm(29450): VFY: unable to resolve exception class 206 (Lnet/sf/json/JSONException;)
11-24 13:20:04.381: W/dalvikvm(29450): VFY: unable to find exception handler at addr 0x2e
11-24 13:20:04.381: W/dalvikvm(29450): VFY: rejected Lnet/sf/json/JSONSerializer;.toJSON (Ljava/lang/Object;Lnet/sf/json/JsonConfig;)Lnet/sf/json/JSON;
11-24 13:20:04.381: W/dalvikvm(29450): VFY: rejecting opcode 0x0d at 0x002e
11-24 13:20:04.381: W/dalvikvm(29450): VFY: rejected Lnet/sf/json/JSONSerializer;.toJSON (Ljava/lang/Object;Lnet/sf/json/JsonConfig;)Lnet/sf/json/JSON;
11-24 13:20:04.381: W/dalvikvm(29450): Verifier rejected class Lnet/sf/json/JSONSerializer;
It seems so that I imported this Libary the false Way, how can I use this Libary in my Android-Project, how do I need to import it that I can use it?
Thx for your help in Advance
safari
PS: I know there is a JSON-Libary in it, but I like to use this one, how can I realize
that? To import the Libaries I tried this: How to Import Java-Libaries, but dosn’t work 🙁
What also looks a bit strange, the libaries don’t show up in “External Libaries” it looks like this:

The reason for your problem is, that the
JSONExceptionextends theNestableRuntimeExceptionfrom the Apache Commons Lang project. So you need to include that jar as well.