问题描述
我知道这个问题已经很多次了,但相信我已经检查了。大部分问题建议删除 import android.R,删除xml文件中的任何错误,检查文件的名称(无大写字母),然后重建和清理项目或重新启动eclipse 。我已经尝试过,但没有解决问题。我清理所有项目时出现问题。现在所有的项目都显示错误。由于所有的项目在我清理项目之前都运行得很好,所有项目的布局或文件名都突然出现,所以没有可能出现错误。
gen
文件夹中也没有文件。据我所知,在构建路径
或首选项
可能会导致错误的方向? !
确保您安装了 Android构建工具
form sdk manager
项目右键属性 - > Java BuildPath选择库并添加 android-support.jar
按照这些步骤。
转到项目 - >属性 - > Java构建路径,而不是选择订单和导出选项卡。设置 android-support .jar
库检查并将其添加到列表的顶部。并且清理和重建。它适用于大多数情况
I know this question has been many times but trust me I have checked all. Most of the question suggests to remove import android.R , remove any error in the xml file, checking name of the files (no capital letters) then rebuild and clean the project or restart eclipse. I have tried all but none solved the problem.The problem occured when i cleaned all the projects. Now all the projects are showing that error. Since all the project were running perfectly before i cleaned projects, there is no possibility that all of the sudden the layouts or the file names of all the projects have error in them.
Also there is no file in gen
folder. As far as i can understand there is something wrong with the build path
or preferences
can anyne point me in a correct direction? !
Make sure you installed the Android build tool
form sdk manager
project right click properties-> Java BuildPath select Library and add android-support.jar
the follow these step.
Go to Project->Properties->Java Build Path than select Order and export tab. Set android-support .jar
library checked and up it into top of the list. And clean and rebuild..It works for most of the cases
这篇关于“R不能解决”可能有错误的构建路径或库导入的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!