0

I have a problem with some library from flashiz. I need to extends a class but when I do that i have a ClassNotFoundException. But he finds the class before i running my app.

Maybe i didnt implemnt the library good.

these are the steps that i took:

right click on project --> android - then add the library and in the java build path

04-29 11:06:43.349: E/AndroidRuntime(6796): FATAL EXCEPTION: main
04-29 11:06:43.349: E/AndroidRuntime(6796): java.lang.RuntimeException: Unable to instantiate application be.genius.gticket.adapter.MyApplicationClass: java.lang.ClassNotFoundException: be.genius.gticket.adapter.MyApplicationClass
04-29 11:06:43.349: E/AndroidRuntime(6796):     at android.app.LoadedApk.makeApplication(LoadedApk.java:482)
04-29 11:06:43.349: E/AndroidRuntime(6796):     at android.app.ActivityThread.handleBindApplication(ActivityThread.java:3955)
04-29 11:06:43.349: E/AndroidRuntime(6796):     at android.app.ActivityThread.access$1300(ActivityThread.java:127)
04-29 11:06:43.349: E/AndroidRuntime(6796):     at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1196)
04-29 11:06:43.349: E/AndroidRuntime(6796):     at android.os.Handler.dispatchMessage(Handler.java:99)
04-29 11:06:43.349: E/AndroidRuntime(6796):     at android.os.Looper.loop(Looper.java:137)
04-29 11:06:43.349: E/AndroidRuntime(6796):     at android.app.ActivityThread.main(ActivityThread.java:4441)
04-29 11:06:43.349: E/AndroidRuntime(6796):     at java.lang.reflect.Method.invokeNative(Native Method)
04-29 11:06:43.349: E/AndroidRuntime(6796):     at java.lang.reflect.Method.invoke(Method.java:511)
04-29 11:06:43.349: E/AndroidRuntime(6796):     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:784)
04-29 11:06:43.349: E/AndroidRuntime(6796):     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:551)
04-29 11:06:43.349: E/AndroidRuntime(6796):     at dalvik.system.NativeStart.main(Native Method)
04-29 11:06:43.349: E/AndroidRuntime(6796): Caused by: java.lang.ClassNotFoundException: be.genius.gticket.adapter.MyApplicationClass
04-29 11:06:43.349: E/AndroidRuntime(6796):     at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:61)
04-29 11:06:43.349: E/AndroidRuntime(6796):     at java.lang.ClassLoader.loadClass(ClassLoader.java:501)
04-29 11:06:43.349: E/AndroidRuntime(6796):     at java.lang.ClassLoader.loadClass(ClassLoader.java:461)
04-29 11:06:43.349: E/AndroidRuntime(6796):     at android.app.Instrumentation.newApplication(Instrumentation.java:942)
04-29 11:06:43.349: E/AndroidRuntime(6796):     at android.app.LoadedApk.makeApplication(LoadedApk.java:477)
04-29 11:06:43.349: E/AndroidRuntime(6796):     ... 11 more

here you see the imports of the library in the class.

import com.mobey.fragment.intern.listener.SDKCallBackListener;
import com.mobey.fragment.abs.SDKLinkFragmentActivity;
public class PaymentActivity extends SDKLinkFragmentActivity implements SDKCallBackListener {
NoiZeR
  • 135
  • 2
  • 11
  • Did you also add the JAR file to the lib folder? if not right click the lib folder, select import,select file system, and then select the JAR. I had a similar problem and worked through it here : [Eclipse Android Project Throws Class Not Found Error During Runtime](http://stackoverflow.com/questions/23164627/eclipse-android-project-throws-class-not-found-error-during-runtime) – Semicolons and Duct Tape Apr 29 '14 at 10:29
  • the Flashiz SDK is not a JAR file its a project library. – NoiZeR Apr 29 '14 at 11:20
  • have you declare library main activity in your project mainifest file – Santosh Dhoundiyal Apr 29 '14 at 11:32
  • No but on the website of Flashiz they dont say anything about it and i dont know how to implement it in the Manifest file. here you can find the website of flashiz : http://developer.flashiz.com/2013-06-21-23-44-26/sdk/android-sdk/framework-installation – NoiZeR Apr 29 '14 at 11:38
  • its only crashes when i run. i dont know what it can be – NoiZeR Apr 29 '14 at 11:44

0 Answers0