r.string错误"不能得到解决或不是场" [英] r.string error "cannot be resolved or is not a field"

查看:110
本文介绍了r.string错误"不能得到解决或不是场"的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我只是开了一个较旧的Andr​​oid应用项目,并突然众多R.string._var_Name错误被发现了。如果我添加导入android.R,那么_var_name成为一个问题说:不能得到解决或不是场。翻译是/res/values​​/strings.xml。任何想法,为什么存在错误?

I just opened an older android app project and all of a sudden numerous R.string._var_Name errors were found. If I add "import android.R" then the _var_name becomes an issue saying "cannot be resolved or is not a field". The translation is in /res/values/strings.xml . Any ideas why the error exists?

推荐答案

在我的情况下,进口android.R通常是问题。然后我删除,然后重新生成(蚀),比它的工作。清洁项目往往也有帮助。

In my case import android.R was usually the problem. I then removed it and build again (eclipse) and than it worked. Cleaning the project often helps too.

这篇关于r.string错误"不能得到解决或不是场"的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆