[英]The prefix “android” for attribute “android:id” associated with an element type “ListView” is not bound
I keep getting this error 我不断收到这个错误
The prefix "android" for attribute "android:id" associated with an element type "ListView" is not bound. 与元素类型“ ListView”相关联的属性“ android:id”的前缀“ android”未绑定。
bit of code where the error is 错误所在的代码位
<ListView
android:id="@android:id/list"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:choiceMode="singleChoice">
</ListView>
It works when this code isnt in the first veiw state when in flex as If i create another component the code works But I need it in the homeview to display the list of items the id is refering to but keeps saying undefined state 当此代码不在flex时处于第一个状态时,它可以工作,如如果我创建另一个组件,则代码可以工作,但是我需要在homeview中显示id所引用的项目列表,但一直说未定义状态
` `
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="wrap_content"
android:layout_height="wrap_content">
<s:List
android:id="@+id/Games"
android:layout_width="fill_parent"
android:layout_height="fill_parent">
</s:List>
</LinearLayout>
` `
I think you should change the @android:id/list to @+id/list 我认为您应该将@android:id / list更改为@ + id / list
<ListView
android:id="@+id/list"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:choiceMode="singleChoice">
</ListView>
This should work! 这应该工作!
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.