'android.content.res.Resources$NotFoundException Error for android below Androdi 6

Hi Professional. I need help.

I was testing my android on the test lab firebase, and I got below errors :

android.content.res.Resources$NotFoundException: Resource ID #0x7f0700cc
     FATAL EXCEPTION: main
Process: com.mathar.tvonlineindonesia, PID: 7449
android.content.res.Resources$NotFoundException: Resource ID #0x7f0700cc
    at android.content.res.Resources.getValue(Resources.java:2598)
    at androidx.appcompat.widget.ResourceManagerInternal.loadDrawableFromDelegates(ResourceManagerInternal.java:252)
    at androidx.appcompat.widget.ResourceManagerInternal.getDrawable(ResourceManagerInternal.java:139)
    at androidx.appcompat.widget.ResourceManagerInternal.getDrawable(ResourceManagerInternal.java:132)
    at androidx.appcompat.content.res.AppCompatResources.getDrawable(AppCompatResources.java:104)
    at androidx.appcompat.view.menu.MenuItemImpl.getIcon(MenuItemImpl.java:505)
    at androidx.appcompat.view.menu.ActionMenuItemView.initialize(ActionMenuItemView.java:126)
    at androidx.appcompat.widget.ActionMenuPresenter.bindItemView(ActionMenuPresenter.java:207)
    at androidx.appcompat.view.menu.BaseMenuPresenter.getItemView(BaseMenuPresenter.java:188)
    at androidx.appcompat.widget.ActionMenuPresenter.getItemView(ActionMenuPresenter.java:193)
    at androidx.appcompat.widget.ActionMenuPresenter.flagActionItems(ActionMenuPresenter.java:473)
    at androidx.appcompat.view.menu.MenuBuilder.flagActionItems(MenuBuilder.java:1182)
    at androidx.appcompat.view.menu.BaseMenuPresenter.updateMenuView(BaseMenuPresenter.java:96)
    at androidx.appcompat.widget.ActionMenuPresenter.updateMenuView(ActionMenuPresenter.java:226)
    at androidx.appcompat.view.menu.MenuBuilder.dispatchPresenterUpdate(MenuBuilder.java:298)
    at androidx.appcompat.view.menu.MenuBuilder.onItemsChanged(MenuBuilder.java:1069)
    at androidx.appcompat.view.menu.MenuBuilder.startDispatchingItemsChanged(MenuBuilder.java:1096)
    at androidx.appcompat.app.ToolbarActionBar.populateOptionsMenu(ToolbarActionBar.java:461)
    at androidx.appcompat.app.ToolbarActionBar$1.run(ToolbarActionBar.java:56)
    at android.os.Handler.handleCallback(Handler.java:739)
    at android.os.Handler.dispatchMessage(Handler.java:95)
    at android.os.Looper.loop(Looper.java:148)
    at android.app.ActivityThread.main(ActivityThread.java:7406)
    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)

I dont know where to start debugging this error, I found that these errors only show on android 6 and below. I found on the stackoverflow about this error but I have no clue for this. The only thing that I think there is the problem with the appcompat version, but I dont have idea for this. Hope you can help me.

Thanks.



Solution 1:[1]

Your problem is the wrong placement of resources(images). You use (API 23) but resources for API 23 is null, because they only API 24 and up. 1-photo

Now all images marked (v24) this means that they are in drawables-v24 just move in drawable

2-photo

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Cona Mobile