Discussion Forums  >  Uncategorized

Replies: 11    Views: 228

plknudson
Aspiring developer
Profile
Posts: 39
Reg: Jul 11, 2011
Cambridge, MA
390
01/04/12 02:46 PM (14 years ago)

android app crashing in the simulator

Hi guys. Having some trouble launching the app in the AVD in Eclipse. I am running Eclipse SDK 3.7 on a Mac 10.6.8. Installed the ADT, Android SDK, and my app targeting the Google APIs (Android 2.2). I launch the simulator, it installs my app sucessfully,but when I try to run it, I see the spiny wheel of death for a bit, and then it crashes telling me it Crashed unexpectedly.) The simulator also takes a while to load sometimes, and not others. Additionally, I tried to see if I could get the Hello World app from Google to work, with the same error happening there as well. Any ideas what I might be doing wrong? Many thanks in advance. Rock on!
 
Fred@mySkylla com
Android Fan
Profile
Posts: 5259
Reg: Oct 03, 2011
location unknow...
62,560
like
01/04/12 03:10 PM (14 years ago)
Do you have access to an android device?
 
Fred@mySkylla com
Android Fan
Profile
Posts: 5259
Reg: Oct 03, 2011
location unknow...
62,560
like
01/04/12 03:25 PM (14 years ago)
Simulator is always slow.
 
plknudson
Aspiring developer
Profile
Posts: 39
Reg: Jul 11, 2011
Cambridge, MA
390
like
01/04/12 11:16 PM (14 years ago)
I have access to one --- but it still is crashing in the simulator once it launches which is concerning to me. Any ideas?
 
Fred@mySkylla com
Android Fan
Profile
Posts: 5259
Reg: Oct 03, 2011
location unknow...
62,560
like
01/05/12 07:43 AM (14 years ago)
I'm new as most are, so try to narrow down the problem. Export the apk to the device http://wp.me/p1ZRa7-2g If the Apk works then the problem is the emulator. If you cannot export then you'll learn something about the problem. Fred
 
Fred@mySkylla com
Android Fan
Profile
Posts: 5259
Reg: Oct 03, 2011
location unknow...
62,560
like
01/05/12 07:45 AM (14 years ago)
 
plknudson
Aspiring developer
Profile
Posts: 39
Reg: Jul 11, 2011
Cambridge, MA
390
like
01/05/12 01:18 PM (14 years ago)
Thanks, I will try to install it on a device and report back.
 
plknudson
Aspiring developer
Profile
Posts: 39
Reg: Jul 11, 2011
Cambridge, MA
390
like
01/05/12 02:25 PM (14 years ago)
Haven't tried the android device yet, but I have this information from the LogCat where the app crashes: 01-05 15:19:45.956: E/AndroidRuntime(324): FATAL EXCEPTION: main 01-05 15:19:45.956: E/AndroidRuntime(324): java.lang.RuntimeException: Unable to resume activity {com.drinkly/com.drinkly.BT_screen_splash}: java.lang.NumberFormatException: unable to parse '5.5' as integer 01-05 15:19:45.956: E/AndroidRuntime(324): at android.app.ActivityThread.performResumeActivity(ActivityThread.java:3128) 01-05 15:19:45.956: E/AndroidRuntime(324): at android.app.ActivityThread.handleResumeActivity(ActivityThread.java:3143) 01-05 15:19:45.956: E/AndroidRuntime(324): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2684) 01-05 15:19:45.956: E/AndroidRuntime(324): at android.app.ActivityThread.access$2300(ActivityThread.java:125) 01-05 15:19:45.956: E/AndroidRuntime(324): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2033) 01-05 15:19:45.956: E/AndroidRuntime(324): at android.os.Handler.dispatchMessage(Handler.java:99) 01-05 15:19:45.956: E/AndroidRuntime(324): at android.os.Looper.loop(Looper.java:123) 01-05 15:19:45.956: E/AndroidRuntime(324): at android.app.ActivityThread.main(ActivityThread.java:4627) 01-05 15:19:45.956: E/AndroidRuntime(324): at java.lang.reflect.Method.invokeNative(Native Method) 01-05 15:19:45.956: E/AndroidRuntime(324): at java.lang.reflect.Method.invoke(Method.java:521) 01-05 15:19:45.956: E/AndroidRuntime(324): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:868) 01-05 15:19:45.956: E/AndroidRuntime(324): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:626) 01-05 15:19:45.956: E/AndroidRuntime(324): at dalvik.system.NativeStart.main(Native Method) 01-05 15:19:45.956: E/AndroidRuntime(324): Caused by: java.lang.NumberFormatException: unable to parse '5.5' as integer 01-05 15:19:45.956: E/AndroidRuntime(324): at java.lang.Integer.parse(Integer.java:433) 01-05 15:19:45.956: E/AndroidRuntime(324): at java.lang.Integer.parseInt(Integer.java:422) 01-05 15:19:45.956: E/AndroidRuntime(324): at java.lang.Integer.parseInt(Integer.java:382) 01-05 15:19:45.956: E/AndroidRuntime(324): at com.drinkly.BT_screen_splash.onResume(BT_screen_splash.java:104) 01-05 15:19:45.956: E/AndroidRuntime(324): at android.app.Instrumentation.callActivityOnResume(Instrumentation.java:1149) 01-05 15:19:45.956: E/AndroidRuntime(324): at android.app.Activity.performResume(Activity.java:3823) 01-05 15:19:45.956: E/AndroidRuntime(324): at android.app.ActivityThread.performResumeActivity(ActivityThread.java:3118) 01-05 15:19:45.956: E/AndroidRuntime(324): ... 12 more
 
GoNorthWest
buzztouch Evangelist
Profile
Posts: 8197
Reg: Jun 24, 2011
Oro Valley, AZ
1,000,000
like
01/05/12 04:01 PM (14 years ago)
Hi @plknudson, Just saw your Tweet...sorry for the delay! From what you posted above, it looks like this might be related to the splash screen for some reason? Perhaps you should remove that from your app, and see if you can get past the crash. If you can, that narrows down the debug a bit. If it still crashes without the splash screen configured, paste more LogCat data and we can go from there. Thanks! Mark
 
plknudson
Aspiring developer
Profile
Posts: 39
Reg: Jul 11, 2011
Cambridge, MA
390
like
01/06/12 05:04 PM (14 years ago)
Installing on Android device still results in crashing. I got rid of the of the splash screen, but still see the same LogCat message. Also - this appears in the error log - not sure if it is relevant but maybe it is: Error Fri Jan 06 17:54:33 CST 2012 Invalid preference page path: XML Syntax Here is the LogCat data - it says error parsing 5.5 as an integer but without the splash screen it shouldn't say that (5.5 was the seconds that the splash screen was on screen for). 01-06 17:58:41.326: E/AndroidRuntime(362): FATAL EXCEPTION: main 01-06 17:58:41.326: E/AndroidRuntime(362): java.lang.RuntimeException: Unable to resume activity {com.drinkly/com.drinkly.BT_screen_splash}: java.lang.NumberFormatException: unable to parse '5.5' as integer 01-06 17:58:41.326: E/AndroidRuntime(362): at android.app.ActivityThread.performResumeActivity(ActivityThread.java:3128) 01-06 17:58:41.326: E/AndroidRuntime(362): at android.app.ActivityThread.handleResumeActivity(ActivityThread.java:3143) 01-06 17:58:41.326: E/AndroidRuntime(362): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2684) 01-06 17:58:41.326: E/AndroidRuntime(362): at android.app.ActivityThread.access$2300(ActivityThread.java:125) 01-06 17:58:41.326: E/AndroidRuntime(362): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2033) 01-06 17:58:41.326: E/AndroidRuntime(362): at android.os.Handler.dispatchMessage(Handler.java:99) 01-06 17:58:41.326: E/AndroidRuntime(362): at android.os.Looper.loop(Looper.java:123) 01-06 17:58:41.326: E/AndroidRuntime(362): at android.app.ActivityThread.main(ActivityThread.java:4627) 01-06 17:58:41.326: E/AndroidRuntime(362): at java.lang.reflect.Method.invokeNative(Native Method) 01-06 17:58:41.326: E/AndroidRuntime(362): at java.lang.reflect.Method.invoke(Method.java:521) 01-06 17:58:41.326: E/AndroidRuntime(362): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:868) 01-06 17:58:41.326: E/AndroidRuntime(362): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:626) 01-06 17:58:41.326: E/AndroidRuntime(362): at dalvik.system.NativeStart.main(Native Method) 01-06 17:58:41.326: E/AndroidRuntime(362): Caused by: java.lang.NumberFormatException: unable to parse '5.5' as integer 01-06 17:58:41.326: E/AndroidRuntime(362): at java.lang.Integer.parse(Integer.java:433) 01-06 17:58:41.326: E/AndroidRuntime(362): at java.lang.Integer.parseInt(Integer.java:422) 01-06 17:58:41.326: E/AndroidRuntime(362): at java.lang.Integer.parseInt(Integer.java:382) 01-06 17:58:41.326: E/AndroidRuntime(362): at com.drinkly.BT_screen_splash.onResume(BT_screen_splash.java:104) 01-06 17:58:41.326: E/AndroidRuntime(362): at android.app.Instrumentation.callActivityOnResume(Instrumentation.java:1149) 01-06 17:58:41.326: E/AndroidRuntime(362): at android.app.Activity.performResume(Activity.java:3823) 01-06 17:58:41.326: E/AndroidRuntime(362): at android.app.ActivityThread.performResumeActivity(ActivityThread.java:3118) 01-06 17:58:41.326: E/AndroidRuntime(362): ... 12 more
 
bananapie
Aspiring developer
Profile
Posts: 23
Reg: Oct 03, 2011
Christchurch, N...
1,230
like
03/02/12 01:45 AM (13 years ago)
I am having the same issue, has anyone resolved this? One of my testers has a phone with a search button and pressing that allows him to get past it.
 
Fred@mySkylla com
Android Fan
Profile
Posts: 5259
Reg: Oct 03, 2011
location unknow...
62,560
like
03/02/12 08:00 AM (13 years ago)
Just noticed you are using a splash screen. As GoNorthwest said above it's the Splash screen. The Android Splash Screen has problems. Solution: Simple, don't use it. You'll need to delete the screen and update the config file to fix this apk. Fred
 

Login + Screen Name Required to Post

pointerLogin to participate so you can start earning points. Once you're logged in (and have a screen name entered in your profile), you can subscribe to topics, follow users, and start learning how to make apps like the pros.