For me just cleaning the project solved the issue
Using Terminal :
./gradlew clean
Using Android Studio :
Build (menu) > Clean Project
More Related Contents:
- Error retrieving parent for item: No resource found that matches the given name after upgrading to AppCompat v23
- Include .so library in apk in android studio [duplicate]
- Using Build Flavors – Structuring source folders and build.gradle correctly
- How do I show dependencies tree in Android Studio?
- gradle – library duplicates in dependencies
- Android Studio marks R in red with error message “cannot resolve symbol R”, but build succeeds
- Android Studio how to package single AAR from multiple library projects?
- AndroidStudio gradle proxy
- Android Studio: Gradle sync failed: Could not HEAD ‘…’. Received status code 502 from server: Bad Gateway [closed]
- A failure occurred while executing com.android.build.gradle.internal.tasks
- Incompatible plugins for android-apt after upgrading to Android Studio 2.3
- Cannot resolve symbol ‘AppCompatActivity’
- Android Studio : Failure [INSTALL_FAILED_OLDER_SDK]
- How to resolve java.util.zip.ZipException?
- how can I add the aidl file to Android studio (from the in-app billing example)
- Android Studio Gradle issue upgrading to version 0.5.0 – Gradle Migrating From 0.8 to 0.9 – Also Android Studio upgrade to 0.8.1
- Run lint when building android studio projects
- Gradle Sync failed could not find constraint-layout:1.0.0-alpha2
- Unable to import Eclipse project to Android Studio
- How to automatically uninstall android app from device before installing a new version
- Could not find com.android.tools.build:gradle:4.0.1 ( or any version )
- Android Studio Run/Debug configuration error: Module not specified
- Android Studio – Unable to find valid certification path to requested target
- Recompile with -Xlint in Android studio
- How to apply plugin to only one flavor in gradle?
- Gradle flavors for android with custom source sets – what should the gradle files look like?
- Android Gradle DexException: Multiple dex files define Lorg/hamcrest/Description
- Import an eclipse android project with version control system into Android Studio
- After update android studio could not create parent directory for lock file
- Android build gradle is too slow (Dependency Resolution)