加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 百科 > 正文

Error处理:关于XML文件解析报错:android XML : unbound prefix

发布时间:2020-12-15 23:24:38 所属栏目:百科 来源:网络整理
导读:编写XML文件的时候,经常回出现android XML : unbound prefix这个错误。 例如: ?xml version="1.0" encoding="utf-8"?set rotate xmlns:Android="http://schemas.android.com/apk/res/android" Android:fromDegrees="0" android:pivotX="50%" android:durat

编写XML文件的时候,经常回出现android XML : unbound prefix这个错误。

例如:

<?xml version="1.0" encoding="utf-8"?>
<set>
    <rotate xmlns:Android="http://schemas.android.com/apk/res/android"
        Android:fromDegrees="0"
        android:pivotX="50%"
        android:duration="0"
        android:interpolator="@android:anim/linear_interpolator"
        android:pivotY="50%"
        android:repeatCount="0"
        android:toDegrees="-90" />
</set>

一不小心它就会跳出来。
这个里面错误的原因是把android写成了Android,Android开发中大小写是敏感的。

错误:android XML : unbound prefix

出现该错误一般有两个原因:

1.拼写错误。例如把android写成了amdroid,Android等

2.xml文档内没有加入 xmlns:android="http://schemas.android.com/apk/res/android" 引用。

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读