Issue
This is the logcat on android studio and what does it mean? If you need more informations please tell me.
4940-4940/werp.moodle E/AndroidRuntime: FATAL EXCEPTION: main
Process: werp.moodle, PID: 4940
java.lang.RuntimeException: Unable to start activity ComponentInfo{werp.moodle/werp.moodle.LLandActivity}: android.content.res.Resources$NotFoundException: Resource ID #0x7f040039
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3254)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3350)
at android.app.ActivityThread.access$1100(ActivityThread.java:222)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1795)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7229)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
Caused by: android.content.res.Resources$NotFoundException: Resource ID #0x7f040039
at android.content.res.Resources.getValue(Resources.java:2558)
at android.content.res.Resources.loadXmlResourceParser(Resources.java:4364)
at android.content.res.Resources.getLayout(Resources.java:2372)
at android.view.LayoutInflater.inflate(LayoutInflater.java:427)
at android.view.LayoutInflater.inflate(LayoutInflater.java:380)
at com.android.internal.policy.PhoneWindow.setContentView(PhoneWindow.java:474)
at android.app.Activity.setContentView(Activity.java:2387)
at werp.moodle.LLandActivity.onCreate(LLandActivity.java:52)
at android.app.Activity.performCreate(Activity.java:6876)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1135)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3207)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3350)
at android.app.ActivityThread.access$1100(ActivityThread.java:222)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1795)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7229)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
Solution
This error means it cannot find the resource it is looking for.There is no single way to fix this.First clean your project and rebuild.Sometimes when you do changes like deletion the cache in a.studio pulls out this thing an a simple cleaning can do the job .
After your clean if its still there it means that you have missing some resource for sure.
1.First check the all relevant classes are linked to menifest
2.This error mostly occurs with an ID so if you have initialized something in your activity check those views are linked (even they linked the order is important so check the flow/if you inflate a layout please be careful)
3.Check that you have accidentally deleted a resource like an drawable image,color code if you did, check if you still try to use those deleted ones
4.sometimes when you generate an id for a view in a run time can also pullout this error!
Answered By - Charuāļ
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.