App crashes on startup (Android)

The app crashes and I get a popup that says “unfortunately app has been stopped”.
I get this error when running the app on some older android (4.3, 4.4). But it works on 4.4.4 and iOS.
Any ideas?

java.lang.RuntimeException: Unable to instantiate activity ComponentInfo{se.toxic.myapp/se.toxic.myapp.MYAPP}: java.lang.ClassNotFoundException: Didn't find class "se.toxic.myapp.MYAPP" on path: /data/app/se.toxic.myapp-1.apk
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2219)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2349)
at android.app.ActivityThread.access$700(ActivityThread.java:159)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1316)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:176)
at android.app.ActivityThread.main(ActivityThread.java:5419)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:525)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1046)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:862)
at dalvik.system.NativeStart.main(Native Method)
Caused by: java.lang.ClassNotFoundException: Didn't find class "se.toxic.myapp.MYAPP" on path: /data/app/se.toxic.myapp-1.apk
at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:64)
at java.lang.ClassLoader.loadClass(ClassLoader.java:501)
at java.lang.ClassLoader.loadClass(ClassLoader.java:461)
at android.app.Instrumentation.newActivity(Instrumentation.java:1078)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2210)
1 Like

hmmm, the problem seems to be cause because of this: https://issues.apache.org/jira/browse/CB-7827
(in cordova 4.0 there’s a bug(?) when you build, it doesnt set the android:name in AndroidManifest.xml to the name you’ve set in config.xml (it sets it to CordovaApp).

To fix this I manually changed android:name in AndroidManifest.xml to my apps name. But that’s not enough!. You’ll have to change some more stuff (see apache-link above).

Hi. I have this problem as well after updating my app (“Unfortunately, {{appname}} has stopped”).
Is there another solution? or maybe a way to debug the cause of this generic error?
I tried the solution listed above.

Thanks

Did you change the name in android manifest.xml?

Is there any other solution I’ve tried this and it still hasn’t worked for me