-1

I have an application with several activities.

Couple of them just a simple menues.

Just a linear layout. A couple of buttons

I've never seen the errors below during development and debugging on my mobile.

But crash reports and complains from users show that sometimes by app just forse closes and iirritates people.

Example of errors are below.

Any ideas where to dig?

Sorry, I can not show sources right now. I will add them in several hours.

Layout were created in Ecliple android plugin. No extra stuff.

Number 1

java.lang.RuntimeException: Unable to start activity ComponentInfo{com.reality.weapons.ak47/com.reality.weapons.ak47.MultiMenu}: android.view.InflateException: Binary XML file line #2: Error inflating class java.lang.reflect.Constructor
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2297)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2313)
at android.app.ActivityThread.handleRelaunchActivity(ActivityThread.java:3307)
at android.app.ActivityThread.access$2100(ActivityThread.java:115)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1725)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:123)
at android.app.ActivityThread.main(ActivityThread.java:3977)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:521)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:782)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:540)
at dalvik.system.NativeStart.main(Native Method) Caused by: android.view.InflateException: Binary XML file line #2: Error inflating class java.lang.reflect.Constructor
at android.view.LayoutInflater.createView(LayoutInflater.java:512)
at com.android.internal.policy.impl.PhoneLayoutInflater.onCreateView(PhoneLayoutInflater.java:56)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:562)
at android.view.LayoutInflater.inflate(LayoutInflater.java:385)
at android.view.LayoutInflater.inflate(LayoutInflater.java:320)
at android.view.LayoutInflater.inflate(LayoutInflater.java:276)
at com.android.internal.policy.impl.PhoneWindow.setContentView(PhoneWindow.java:313)
at android.app.Activity.setContentView(Activity.java:1683)
at com.reality.weapons.ak47.MultiMenu.onCreate(MultiMenu.java:75)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1123)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2260)

============================

number 2

java.lang.RuntimeException: Unable to start activity ComponentInfo{com.reality.weapons.ak47/com.reality.weapons.ak47.MultiMenu}: android.content.res.Resources$NotFoundException: Resource ID #0x7f030005
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2753)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2769)
at android.app.ActivityThread.handleRelaunchActivity(ActivityThread.java:3905)
at android.app.ActivityThread.access$2600(ActivityThread.java:129)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2121)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:143)
at android.app.ActivityThread.main(ActivityThread.java:4717)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:521)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:860)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:618)
at dalvik.system.NativeStart.main(Native Method) Caused by: android.content.res.Resources$NotFoundException: Resource ID #0x7f030005
at android.content.res.Resources.getValue(Resources.java:901)
at android.content.res.Resources.loadXmlResourceParser(Resources.java:1897)
at android.content.res.Resources.getLayout(Resources.java:740)
at android.view.LayoutInflater.inflate(LayoutInflater.java:318)
at android.view.LayoutInflater.inflate(LayoutInflater.java:276)
at com.android.internal.policy.impl.PhoneWindow.setContentView(PhoneWindow.java:226)
at android.app.Activity.setContentView(Activity.java:1677)
at com.reality.weapons.ak47.MultiMenu.onCreate(MultiMenu.java:75)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1047)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2717)

============================

user929298
  • 559
  • 1
  • 5
  • 13

2 Answers2

0

Can you check you layouts. Not sure where without looking at your layout XML files, but it looks like there's a problem creating the layout, i.e. a resource not being found. Resources$NotFoundException: Resource ID #0x7f030005

If you can post more than the stack traces it'll be easier to see what's up.

Kyle Clegg
  • 38,547
  • 26
  • 130
  • 141
0

Seems to be the version issue. In which Android version you are getting this error ?. Does your program have graphical resources ?.

Android 1.5 doesn't support drawable-Xdpi folders, so you will have to create a drawable folder, and put all content there.

You can hv a look here...http://stackoverflow.com/questions/2923823/android-2-2-sdk-breaks-compatibility-with-older-phones

Shashank Kadne
  • 7,993
  • 6
  • 41
  • 54