1

I am in a weird situation, which I have no idea what's going on.

The code was working, until I upgraded my Android SDK to r17.

The code is able to compile, but during runtime, Eclipse throws ClassNotFoundException(), under findClass method, in PathClassLoader.class

The class that not found are "org.apache.http.entity.mime.content.ContentBody" and "org.apache.http.entity.mime.content.StringBody"

I already imported in the latest (4.1.3) http components jar file into project-> properties-> java build path-> add external jar,

and also clear my project N-times, yet nothing seems work.

This is from the logcat:

03-27 17:31:32.461: W/dalvikvm(14263): VFY: unable to find class referenced in signature (Lorg/apache/http/entity/mime/content/ContentBody;)
03-27 17:31:33.802: E/dalvikvm(14263): Could not find class 'org.apache.http.entity.mime.content.StringBody', referenced from method com.milotin.core.base.MTBaseNetworkUtilities.getContentBody
03-27 17:31:33.802: W/dalvikvm(14263): VFY: unable to resolve new-instance 710 (Lorg/apache/http/entity/mime/content/StringBody;) in Lcom/milotin/core/base/MTBaseNetworkUtilities;

(sorry for the messy paste, is actually just 3 lines from logcat)

My TargetSDK is API10, and MinSDK is API8.

What is the reason??

Padma Kumar
  • 19,893
  • 17
  • 73
  • 130
VHanded
  • 2,079
  • 4
  • 30
  • 55
  • 1
    Long story short, the Android SDK changed how it tracks dependencies within your project. Please search StackOverflow for Android r17. One of the other threads probably answers your question. – Sparky Mar 27 '12 at 09:40
  • Yes!! That is the culprit!! I used to put those .jar files outside my project, now I moved them into my project/lib folder, and problem solved. Here is where I got my solution: http://stackoverflow.com/questions/9838069/jar-file-issue-with-adt-r17 – VHanded Mar 27 '12 at 09:56

1 Answers1

0

Yes!! r17 is the culprit!! I used to put those .jar files outside my project, now I moved them into my project/lib folder, and problem solved. Here is where I got my solution: Jar-file issue with ADT r17

Thanks!

Community
  • 1
  • 1
VHanded
  • 2,079
  • 4
  • 30
  • 55