Android Studio “cannot resolve symbol” but project compiles and works

后端 未结 13 2294
我在风中等你
我在风中等你 2020-12-24 10:49

The project compiles fine. However, Android studio 3.0.1 shows reference to one particular library in red and displays \"cannot resolve symbol\". Even single stepping into

13条回答
  •  抹茶落季
    2020-12-24 11:15

    This has happened to me a couple of times, there are a few ways you can resolve this problem;

    1. Sync project files with gradle in the File toolbar
    2. Use the Invalidate/Restart option in the File toolbar to invalidate the caches.
    3. Delete the .idea folder and restart Android Studio

提交回复
热议问题