Android Gradle: can't find symbol variable

霸气de小男生 提交于 2019-12-05 09:50:29

You have imported android.R, which only includes core framework resources. You need to change this to com.example.package.R, where com.example.package is your applications resource package name.

EDIT (MashedPotatoes): I forced a JPG file to be PNG without proper conversion, that's what caused the errors. But the original error was caused by importing android.R, not com.example.package.R, so marking this as correct.

For me the error had nothing to do with imports and simply was dealing with a .JPG that had a .PNG file extension. Renaming the file extension fixed the problem.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!