去除代码activity代码页面顶部中的 import android.R;这句
就可以消除红色波浪线的main cannot be resolved or is not a field类似这个错误了

layout cannot be resolved or is not a field的更多相关文章

  1. Andrion错误解决:cannot be resolved or is not a field

    cannot be resolved or is not a field   解决这个问题:   选择project菜单中的clean,选择你的项目,先clean一下, 再去看看Activity中有没 ...

  2. "cannot be resolved or is not a field"问题解决 (转载)

    转自:http://blog.csdn.net/liranke/article/details/16803295 在修改了资源文件后,出现“"cannot be resolved or is ...

  3. R.id.layout等不能识别:cannot be resolved or is not a field

    Do not modify the R class. The error means there's something syntactically wrong with your XML layou ...

  4. “main cannot be resolved or is not a field”解决方案

    .layout.main总是在layout上有错误提示波浪线. 解决方法: (1) 删除"import android.R;". (2) 勾选上Eclipse中的"Pro ...

  5. 出现 cannot be resolved or is not a field 错误

    删除R.Java文件,这时,系统会重新生成一个R.java; 删除java代码中的"import Android.R"文件. 重新导入正确的包.

  6. main cannot be resolved or is not a field

    今天在做XML解析的时候,总是给我报 XML Parsing Error: XML or text declaration not at start of entity 的错误,后来查了下讲大概意思是 ...

  7. Android错误之--activity_main cannot be resolved or is not a field

    一般在copy别人的项目中会easy出现本错误,截图例如以下:

  8. raw cannot be resolved or is not a field解决办法

    解决raw文件夹问题 查看左侧项目/res文件夹下是否有raw文件夹,(一定是放到res文件夹下,raw在项目开始创建时候不会自动创建,所以要自己创建)

  9. setContentView(R.layout.activity_main)无法正常引用

    今天在写Android代码的过程中,编译器一直报错,错误出在这一行代码: setContentView(R.layout.activity_main) 提示信息是: activity_main can ...

随机推荐

  1. windows7环境下 硬盘安装ubuntu 12.04 server版

    之前一直用windows7环境下的虚拟机装的操作系统,但有时候在切换系统时老是死机,还是装一个硬盘版的ubuntu 12.04 server吧 先说一下本人的环境吧:windows 7 32位专业版+ ...

  2. 淡淡de馨香---职业尊严

    大学四年时光匆匆而过,仿佛一切都不曾远去,那种熟悉又激动的感觉好似就在昨天,但是.一切都仅仅是一种感觉,在现实面前没有谁能够逆天,在被遗忘的什么时候,曾经是想着无数的梦想与自定义,同样也是在被遗忘的什 ...

  3. Raid1源代码分析--读流程(重新整理)

    五.Raid1读流程分析 两个月前,刚刚接触raid1,就阅读了raid1读流程的代码,那个时候写了一篇博客.现在回过头看看,那篇的错误很多,并且很多地方没有表述清楚.所以还是决定重新写一篇以更正之前 ...

  4. Ext中图片上传预览的问题,困扰了好几天终于解决了,记录下

    { columnWidth:.50, xtype:'textfield', style:"padding-top:5px", name:'goodsMainPhoto', id:' ...

  5. MyBatis配置解析

    MyBatis配置文件解析(概要) 1.configuration:根元素 1.1 properties:定义配置外在化 1.2 settings:一些全局性的配置 1.3 typeAliases:为 ...

  6. POJ 3450 Corporate Identity (KMP+暴搞)

    题意: 给定N个字符串,寻找最长的公共字串,如果长度相同,则输出字典序最小的那个. 找其中一个字符串,枚举它的所有的字串,然后,逐个kmp比较.......相当暴力,可二分优化. #include & ...

  7. const与define的异同

    1. DEFINE是预处理指令,是简单的文字替换:而const是关键字,用于变量声明的修饰. 2. DEFINE替换的结果可以是数值.表达式.字符串.甚至是一个程序:而const只能限定变量为不可修改 ...

  8. Mysql 细节记忆

    DELIMITER $$ 和 DELIMITER ; DROP PROCEDURE IF EXISTS `pro_follow_getBookBeforeExpired`$$ DECLARE p_Se ...

  9. 动态绑定GridView数据源遇到问题

    1.GridView中的Button控件响应Command事件的时候出现System.ArgumentException: 回发或回调参数无效, 设置<pages enableEventVali ...

  10. WebApi2官网学习记录---Html Form Data

    HTML Forms概述 <form action="api/values" method="post"> 默认的method是GET,如果使用GE ...