Android Studio - Error:resource drawable/abc_ic_ab_back_mtrl_am_alpha (aka com.instacoin:drawable/abc_ic_ab_back_mtrl_am_alpha) not found

后端 未结 7 1152
暗喜
暗喜 2021-01-05 06:36

I am getting these errors:

Error:resource drawable/abc_ic_ab_back_mtrl_am_alpha (aka com.instacoin:drawable/abc_ic_ab_back_mtrl_am_alpha) not found.

相关标签:
7条回答
  • 2021-01-05 07:28

    i was searching for exactly this error in a few threads and would like anyone who experiences a situation like this to do these steps:

    situation:

    android studio is throwing errors like @drawable/... not found even renaming files does not solve the problem

    solution steps

    1. double check the file ( is it present? is the filename valid?)
    2. if you can examine an error fix it and run an clean / rebuild of the project
    3. if this didnt help take the time and use Android Lint its found at Analyse -> inspect code ... it takes some time but its worth it and now ...
    4. fix every error shown, this isnt a joke those errors could prevent you from building the target. do a clean / rebuild
    5. now if this still does not work here are the stranges things ive seen:

      • in the filename is an invalid char which doesnt show up in the list or at renaming
      • the file is converted but its empty
      • an file is reverted by git but was deleted in future commits
      • after an code cleanup an xml tag is missing its counterpart

    where does these errors come from and why they dont show up in the log

    android studio is doing an incremental build , so files are proccessed and used again if they weren't changed. this leads to the following behaviour:

    running an build -> collecting files -> proccessing files -> an error occured

    all other files in the queue arent found as the couldn't get proccessed by build step the following error is shown as the last error occured aka @drawable not found

    0 讨论(0)
提交回复
热议问题