I would like to fix this error
R cannot be resolved to a variable
I looked up many answers, but I could not get the right one;
All the above suggestions should work normally, if you are still facing issue I suspect you are using 64bit OS and ADT is looking for 32bit binaries
try executing below command in terminal and clean the project once
sudo apt-get install ia32-libs
I had this problem and turns out this was due to an error in one of my layout xml files that I had just changed
i lived with this problem for 2 weeks and today i find the solution that is "icrease (MINIMUM SDK REQUIRED) to maximum possible"
This error is because of deleting R.java
file from project /gen
folder. If you have backup of your project, please go to the project directory and paste R.java
file which you copy from your backup section.
Corrupt R.java file can also be caused by an error in XML. Often these kinds of errors don't show up in eclipse, so I'd suggest taking a look at your XML files. After that you can also try to Clean
your project by going to Project -> Clean...
in the menu bar.