Warning: file_get_contents(/data/phpspider/zhask/data//catemap/0/xml/12.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
xml呈现此$0 android studio时出错_Android_Xml - Fatal编程技术网

xml呈现此$0 android studio时出错

xml呈现此$0 android studio时出错,android,xml,Android,Xml,我收到错误:呈现此$0时引发异常 这是我的xml: <?xml version="1.0" encoding="utf-8"?> ScrollView xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="wrap_content" android:layout_height="wrap_content"> <RelativeLa

我收到错误:呈现此$0时引发异常

这是我的xml:

<?xml version="1.0" encoding="utf-8"?>
ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content">


<RelativeLayout
        xmlns:tools="http://schemas.android.com/tools"
        android:padding="@dimen/activity_horizontal_margin"
        android:id="@+id/fairy_animation"
        android:layout_width="wrap_content"
        android:layout_height="match_parent">

    <TextView
            style="@android:style/TextAppearance.Medium"
            android:id="@+id/textview_language"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_below="@+id/layout_container"
            android:layout_alignBaseline="@+id/button_language"
            android:gravity="center_horizontal"
            android:text="@string/text_is_in"/>

    <Spinner
            tools:listitem="@android:layout/simple_spinner_item"
            android:id="@+id/button_language"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_below="@+id/layout_container"
            android:drawSelectorOnTop="true"
            android:layout_toRightOf="@+id/textview_language"
            android:layout_toEndOf="@+id/textview_language"/>
</RelativeLayout>

ScrollView xmlns:android=”http://schemas.android.com/apk/res/android"
android:layout\u width=“包装内容”
android:layout\u height=“wrap\u content”>

我不知道如何修理它。请帮忙。这方面我是新手。我正在使用android studio 2.0,你必须

change ScrollView.....> to <ScrollView.....>
Add </SCrollView> after </RelativeLayout>
将ScrollView….>更改为
加在后面

参考xml规则以获得更多知识

这一问题来自这一行:

tools:listitem="@android:layout/simple_spinner_item"
您可以通过删除它或使用其他布局来避免它。(例如,
简单列表\项目\ 1


看起来基本相同:

非常感谢!我将其删除,然后显示布局:)