Android Cannot resolve symbol '?attr/selectableItemBackground'

后端 未结 10 1835
北恋
北恋 2020-12-05 09:11


        
相关标签:
10条回答
  • 2020-12-05 09:57

    I faced with same error after updating Kotlin. Solved with "Invalidate caches/Restart"


    UPDATE Today this solution did not helped me. But the solution of this question did: Android Studio 3.1 Cannot Resolve Symbol (Themes, Widget, attr, etc.)

    0 讨论(0)
  • 2020-12-05 09:58

    Both resources are defined with the Android Support Library and since these symbols cannot be resolved, it seems like you're missing to define the support dependency.

    dependencies {
        compile "com.android.support:appcompat-v7:$androidSupportVersion"
    }
    
    0 讨论(0)
  • 2020-12-05 10:00

    I updated my gradle version to 4.10.1 and fix and reimport repaired it. There were no libraries folder under .idea before.

    0 讨论(0)
  • 2020-12-05 10:01

    If you use applicationContext for LayoutInflater, then replace it to normal context. It works for me.

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