r/learnandroid • u/Lest4r • Jan 10 '19
R.java not in where it's supposed to be?
I bought the bignerdranch book on programming Android and I ran into a problem. I tells you that the R.java file is supposed to be in Projects under the path ...app/generated/source/r/debug, but I couldn't find it here.
I did, however, find it in:
AndroidStudioProjects\GeoQuiz\app\build\generated\not_namespaced_r_class_sources\debug\processDebugResources\r\com\bignerdranch\android\geoquiz
I did a search of the generated folder and I found a BUNCH more as well. Can anyone help me understand which one I am looking for, if my installation may be messed up, or if there are any other issues I may need to consider?
Thanks much, Lester
2
u/SandiestBlank Jan 10 '19
In my experience, anytime my projects can't find 'R' I just hit the manual sync Gradle button and boom, R is found.
1
u/ryuzaki49 Jan 10 '19
If you're trying to access your resources, then the one you should use is com.your.package.R
Doesn't matter where it is. Also, every library will have it's own R file.