Android类型错误:解析XML时出错:格式不正确(无效令牌)
我对android/java非常陌生,一直在关注一些youtube教程,在我的一个xml布局上遇到了一个严重的问题 基本上,我在Android类型错误:解析XML时出错:格式不正确(无效令牌),android,xml,Android,Xml,我对android/java非常陌生,一直在关注一些youtube教程,在我的一个xml布局上遇到了一个严重的问题 基本上,我在EditText部分的代码的android:hint上遇到了一个“错误解析XML:not-well format(无效令牌)”错误。谁能告诉我我做错了什么?(顺便说一句,代码有可能是一团乱麻,因为我只是想让它工作而已!) 关闭文本视图的括号谢谢大家。我已关闭文本视图,但问题仍然存在。我现在有一个问题与我的其他类错误与'R不能解决' <?xml version="
EditText
部分的代码的android:hint
上遇到了一个“错误解析XML:not-well format(无效令牌)”错误。谁能告诉我我做错了什么?(顺便说一句,代码有可能是一团乱麻,因为我只是想让它工作而已!)
关闭文本视图的括号谢谢大家。我已关闭文本视图,但问题仍然存在。我现在有一个问题与我的其他类错误与'R不能解决'
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:padding="25dp" >
<EditText
android:id="@+id/etCommands"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:hint="@string/Type a command"
android:inputType="true">
</EditText>
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:weightSum="100" >
<Button
android:id="@+id/bResults"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_weight="20"
android:text="@string/Try Command" >
</Button>
<ToggleButton
android:id="@+id/tbPassword"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_weight="80"
android:checked="true"
android:paddingBottom="3dp"
android:text="@string/ToggleButton" />
</LinearLayout>
<TextView
android:id="@+id/tvResults"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:text="@string/Invalid"
</TextView>
</LinearLayout>
<TextView
android:id="@+id/tvResults"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:text="@string/Invalid"> <--- you forgot to close bracket here
^^^
</TextView>
<EditText
android:id="@+id/etCommands"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:hint="SOME HINT" <---- Just try this testing purpose only
android:inputType="true">
</EditText>