Unexpected namespace prefix "xmlns" found for tag Linear Layout
原文地址http://blog.csdn.net/taxuexumei/article/details/41523419
今天遇到的问题,,,保存到博客里,下回遇到找博客就行了,,,,,,
今天在制作安卓UI嵌套式布局的时候,当出入以下的的代码的时候出现以下情况:
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context="${relativePackage}.${activityClass}" >
<Button
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="北京魔乐科技" />
<LinearLayout
【xmlns:android="http://schemas.android.com/apk/res/android"】
android:orientation="vertical"
android:layout_height="wrap_content"
android:layout_width="wrap_content" >
<ImageView
android:src="@drawable/ic_launcher"
android:layout_height="wrap_content"
android:layout_width="wrap_content"/>
<ImageView
android:src="@drawable/ic_launcher"
android:layout_height="wrap_content"
android:layout_width="wrap_content"/>
</LinearLayout>
<TableLayout
【xmlns:android="http://schemas.android.com/apk/res/android"】
android:orientation="vertical"
android:layout_height="wrap_content"
android:layout_width="wrap_content" >
</TableLayout>
</LinearLayout>
【】此括号内标记的东西出现红色下划线。
出现了以下
Unexpected namespace prefix "xmlns" found for tag LinearLayout
的错误,我的解决方法是
是一个namespace声明只要在xml中出现一次就可以了,多次出现就报错,以前好像没这要求。
只保留第一个声明,后面的直接删除就OK了。
//////////////////////////
有一次升级开发工具后发现xml脚本出现错误“Unexpected namespace prefix "xmlns" found for tag LinearLayout”,原来是一个namespace声明只要在xml中出现一次就可以了,多次出现就报错,以前好像没这要求。
只保留第一个声明,后面的直接删除就OK了。
Unexpected namespace prefix "xmlns" found for tag Linear Layout的更多相关文章
- 错误“Unexpected namespace prefix "xmlns" found for tag LinearLayout”的解决方法(转)
(转自:http://blog.csdn.net/bombzhang/article/details/12676789) 有一次升级开发工具后发现xml脚本出现错误“Unexpected namesp ...
- 错误“Unexpected namespace prefix "xmlns" found for tag LinearLayout”的解决方法
编写布局代码时发现xml脚本出现错误“Unexpected namespace prefix "xmlns" found for tag LinearLayout”,原来是一个na ...
- android常见错误-Unexpected namespace prefix "xmlns" found for tag LinearLayout
有一次升级android开发工具后发现xml脚本出现错误“Unexpected namespace prefix "xmlns" found for tag LinearLayou ...
- error:“Unexpected namespace prefix "xmlns" found for tag LinearLayout”
错误“Unexpected namespace prefix "xmlns" found for tag LinearLayout”的解决方法 androidUnexpected ...
- 【解决方法】Unexpected namespace prefix “xmlns” found for tag Layout
问题描写叙述 出错代码例如以下: <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android&quo ...
- [Android开发常见问题-14] Unexpected namespace prefix "abc" found for tag SomeThing
很多开发者朋友可能会自己定义一些控件,以此来扩展现有控件的功能,在扩展空间的时候通常会自己定义一些属性,例如: [html] view plain copy <android.alex.v ...
- Customize WCF Envelope and Namespace Prefix
转自:http://vanacosmin.ro/Articles/Read/WCFEnvelopeNamespacePrefix Posted on January 8th 2014 by Vana ...
- SVG报错error on line 39 at column 26: Namespace prefix xlink for href on script is not defined
转自:http://stackoverflow.com/questions/3561270/error-on-line-39-at-column-26-namespace-prefix-xlink-f ...
- org.dom4j.IllegalAddException: No such namespace prefix: *** is in scope on: org.dom4j.tree.DefaultElement (dom4j写入XML文件,标签中带【:】(冒号)解决办法)
用dom4j操作写XML文件,标签中含有冒号,会报 org.dom4j.IllegalAddException: No such namespace prefix: *** is in scope o ...
随机推荐
- JS之延迟处理
$(document).ready(function () { $("#zidong3,#zidong1").click(function () { $("#zidong ...
- .NET实现高效过滤敏感查找树算法(分词算法):
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.T ...
- Hibernate 根据实体名称得到DB表名以及表对应的Sequence name
DB: oracle 10g; entityName:com.signaldemand.flank.hibernate.model.实体名 1. 根据实体名获取DB表相对应的表名 Class<? ...
- java多线程-Java中的Copy-On-Write容器
Copy-On-Write简称COW,是一种用于程序设计中的优化策略.其基本思路是,从一开始大家都在共享同一个内容,当某个人想要修改这个内容的时候,才会真正把内容Copy出去形成一个新的内容然后再改, ...
- 字符串链接strcat
#include "stdafx.h" #include "iostream" #include "assert.h" #include & ...
- java项目@override报错问题
有时候Java的Eclipse工程换一台电脑后编译总是@override报错,把@override去掉就好了,但不能从根本上解决问题,因为有时候有@override的地方超级多. 这是jdk的问题,@ ...
- Python爬虫(一) 信息系统集成及服务资质网
警告:不要恶意的访问网站,仅供学习使用! 本教程实例只抓取信息系统集成及服务资质网的企业资质查询. 1. 抓包 打开谷歌浏览器的开发者工具并访问该网站,过滤请求后找到请求数据的包. 1.1 找到相应封 ...
- DOS命令大全(经典收藏)
net use \\ip\ipc$ " " /user:" " 建立IPC空链接 net use \\ip\ipc$ "密码" /user: ...
- Fragment的基本用法
一.Fragment主要用到的API: 1.Fragment 类-----用来创建碎片 2.FragmentManager 类 ----为管理Activity中Fragment,用于Activity与 ...
- hive数据类型学习
Hive的内置数据类型可以分为两大类:(1).基础数据类型:(2).复杂数据类型.其中,基础数据类型包括: TINYINT, SMALLINT, INT, BIGINT, BOOLEAN, FLOAT ...