Android 使用xmlns分析XML未绑定前缀时出错:滑动

Android 使用xmlns分析XML未绑定前缀时出错:滑动,android,xml,layout,xml-namespaces,sliding,Android,Xml,Layout,Xml Namespaces,Sliding,我正在尝试使用,那个imho,看起来很有希望。我喜欢使用它,而不是代码。我有以下非常简单的布局配置 <com.slidingmenu.lib.SlidingMenu xmlns:sliding="http://schemas.android.com/apk/res-auto" android:id="@+id/slidingmenulayout" android:layout_width="match_parent" android:layout_height="match_parent"

我正在尝试使用,那个imho,看起来很有希望。我喜欢使用它,而不是代码。我有以下非常简单的布局配置

<com.slidingmenu.lib.SlidingMenu
xmlns:sliding="http://schemas.android.com/apk/res-auto"
android:id="@+id/slidingmenulayout"
android:layout_width="match_parent"
android:layout_height="match_parent"
sliding:viewAbove="@layout/customforabove"
sliding:viewBehind="@layout/customforbehind"
sliding:behindOffset="120dip"
sliding:behindScrollScale="0.25"

但我说了一个关于未绑定前缀的错误。我不知道是因为xmlns之后的滑动,还是其他原因

Tks提前

我想应该是这样的

xmlns:sliding="http://schemas.android.com/apk/res/auto"
(无破折号)

并将“auto”替换为查找滑动菜单库的程序包名称

尝试:


这应该是您在其中使用的任何资源文件的顶部元素(在xmlns:android旁边是正确的位置)

属性“android:id”、“android:layout\u width”和“android:layout\u height”名称中的“android”也是名称空间前缀,因此,通常需要在标记中的某个位置适当填写一个名为“xmlns:android”的属性。

我刚刚得到了这个答案。 通过执行以下操作修复了此问题:

xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:android="http://schemas.android.com/apk/res/android"