Missing R.java file even though project cleaned

后端 未结 12 1691
猫巷女王i
猫巷女王i 2020-12-03 07:41

Every time in code that I have an R, I get an error R cannot be resolved to a variable.

The R.java file appears to be missing.

I have tried cleaning the proj

12条回答
  •  臣服心动
    2020-12-03 08:32

    If you do not see R.java file generation upon creating an Android project, then you probably have missed downloading Android SDK Tools in the Android SDK Manager. In eclipse, go to Window-->select Android SDK Manager Once the Android SDKManager window opens, check the Tools folder and install. Once the installation is completed, restart the eclipse IDE. Build your project and you can see the R.java file generated under the gen folder of your Android project.

提交回复
热议问题