Ich verstehe nicht, warum ich diese Fehlermeldung bekomme:
Mehrere Anmerkungen in dieser Zeile gefunden:
- Das Markup im Dokument, das auf das Wurzelelement folgt, muss gut formatiert sein.
- Fehler: Fehler beim Parsen von XML: Junk nach Dokumentelement
Der Fehler ist unten zu Beginn von:
LinearLayout
android:orientation="vertical"
android:layout_weight="30"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
XML:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical"
android:weightSum="100">
<ScrollView android:layout_weight="30" android:layout_width="fill_parent"
android:layout_height="fill_parent">
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical">
<TextView
android:id="@+id/textView1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="TextView" />
<EditText
android:id="@+id/editText1"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:ems="10"/>
<TextView
android:id="@+id/textView2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="TextView" />
<EditText
android:id="@+id/editText2"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:ems="10" />
<TextView
android:id="@+id/textView3"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="TextView" />
<EditText
android:id="@+id/editText3"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:ems="10" />
<TextView
android:id="@+id/textView4"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="TextView" />
<EditText
android:id="@+id/editText4"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:ems="10" />
<TextView
android:id="@+id/textView5"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="TextView" />
<EditText
android:id="@+id/editText5"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:ems="10" />
<TextView
android:id="@+id/textView6"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="TextView" />
<EditText
android:id="@+id/editText6"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:ems="10" />
</LinearLayout>
</ScrollView>
<LinearLayout
android:layout_weight="40"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical"/>
<Button android:id="@+id/button1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Button"/>
</LinearLayout>
<LinearLayout
android:orientation="vertical"
android:layout_weight="30"
android:layout_width="fill_parent"
android:layout_height="fill_parent"/>
<AnalogClock
android:id="@+id/analogClock1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"/>
</LinearLayout>
</LinearLayout>
Antworten:
2 für die Antwort № 1<LinearLayout
android:layout_weight="40"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical"/>
<Button android:id="@+id/button1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Button"/>
</LinearLayout>
Du hast ein Extra /
am Anfangstag von LinearLayout
Es gibt eins im nächsten LinearLayout
Gruppe auch