Android Studio 3.1 Cannot Resolve Symbol (Themes, Widget, attr, etc.)

前端 未结 16 1943
梦如初夏
梦如初夏 2020-11-29 01:21

I upgraded Android Studio today to 3.1, and now Android Studio says it cannot resolve symbols for most of the resources (for example ThemeOverlay in style

相关标签:
16条回答
  • 2020-11-29 02:04

    I updated my gradle version to 4.10.1 and did "fix and reimport". There were no libraries folder under .idea before. And then it worked

    0 讨论(0)
  • 2020-11-29 02:04

    How I solved it.:

    I updated Android studio to version 3.2, and two steps solved this problem.

    1. Deleted from Android studio welcome page.

    2. Open project again.

    Worked for me.

    0 讨论(0)
  • 2020-11-29 02:07
    implementation 'com.android.support:appcompat-v7:26.1.0'
    implementation 'com.android.support.constraint:constraint-layout:1.1.2'
    implementation 'com.android.support:design:26.1.0'
    

    update your dependencies with the above in build.gradle(project)

    and put the below code in build.gradle(Module:app)

    classpath 'com.android.tools.build:gradle:3.1.1'
    classpath 'io.realm:realm-gradle-plugin:3.7.1'
    classpath 'com.google.gms:google-services:3.1.0'
    
    0 讨论(0)
  • 2020-11-29 02:08

    Similar error for me when I update to com.android.tools.build:gradle 3.3.1 and gradle-4.10.1

    I have tried the following method but didn't work:

    1. Clean Project - Rebuild Project
    2. Invalidate Caches / Restart
    3. Check .xml error (I didn't find any errors about xml )
    4. Modify .iml file

    I fix this error by modify com.android.tools.build:gradle 3.2.1 and Restart my mac , I didn't know which one can fix it, but it really work for me .

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