Java Android XML错误:文档元素/根元素后的垃圾必须格式正确
我完全不知道我做错了什么我有两个错误-文档元素后的垃圾和根元素后的标记必须格式良好,有什么想法吗Java Android XML错误:文档元素/根元素后的垃圾必须格式正确,java,android,xml,Java,Android,Xml,我完全不知道我做错了什么我有两个错误-文档元素后的垃圾和根元素后的标记必须格式良好,有什么想法吗 <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent" android:layout_height="match_p
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="horizontal"
tools:context=".MainActivity" />
<EditText android:id="@+id/edit_message"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:hint="@string/edit_message" />
</EditText>
<button android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/button_send" />
</LinearLayout>
我看到您至少有两个错误
LinearLayout
不应在顶部声明的末尾添加/
。这可能会导致XML错误李>
按钮
应大写