0

I just converted simple geo java project in to jar file and then added the jar in lib folder in android project.how ever ,when i supposed to run i got the following error.

java.lang.VerifyError: com.simplegeo.client.AbstractSimpleGeoClient

My code is

@Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);
         SimpleGeoPlacesClient client;
         Log.v("DEBUG INFO","setting up client");
         client = SimpleGeoPlacesClient.getInstance();
         client.getHttpClient().setToken("v6twG2W4aHmXk725WryK22wUnXVSmhqT","5wvfksDtH8QSMZeKKcDXaXC3HVDfJVx2");
         Log.v("DEBUG INFO","client is set");
   }

how to solve this.

Kakey
  • 3,760
  • 4
  • 27
  • 45
  • 1. http://stackoverflow.com/questions/100107/reasons-of-getting-a-java-lang-verifyerror 2. http://download.oracle.com/javase/1.4.2/docs/api/java/lang/VerifyError.html 3. http://www.docjar.com/docs/api/java/lang/VerifyError.html check these links – Pankaj Kumar Mar 16 '11 at 16:29
  • possible duplicate of [Android java.lang.VerifyError?](http://stackoverflow.com/questions/668788/android-java-lang-verifyerror) – Matthew Willis Mar 16 '11 at 16:30
  • Look in the "logcat" output. Above the VerifyError stack trace you'll see some detailed messages with "VFY" in them. Post those here. – fadden Mar 16 '11 at 23:45

2 Answers2

1

You probably need to recompile the jar or run it through dx as per this answer.

Android uses a different class file format. Are you running the 3rd party JAR files through the "dx" tool that ships with the Android SDK?

Community
  • 1
  • 1
Matthew Willis
  • 44,037
  • 10
  • 96
  • 87
0

move your jar file from lib to libs folder.

Netverse
  • 1,190
  • 1
  • 8
  • 18