0

私は youtube の thenewboston android アプリ開発の 36 番目のチュートリアルにいます。彼は私たちに私たちのコードをコピーして貼り付けさせました (なぜなら、私たちは今ではその方法を知っているはずだからです)。コピーして貼り付けましたが、うまくいかなかったので、すべて入力してみました。それでもうまくいきませんでした。R.id が機能しません。以前にこれで問題が発生したことがあるので、XML ファイルを確認することを知っていました。そしてそこではすべてが狂っています。Android:layout_width="match_parent" がある場所ならどこでもエラーが発生します。いくつかの調査を行ったところ、「fill_parent」に更新されて変更されたと思いますが、XML で「エラー: XML の解析エラー: 整形式ではありません (無効なトークン)」というエラーが表示されます。何度もやり直してみました。お掃除プロジェクト。再起動しています。コードをトリプルチェックします。何が間違っているのかわかりません。みんなを助けてください!気が狂いそう!! ありがとうございます。

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:weightSum="100"
<ScrollView
    android:layout_weight="30"
    android:layout_width="fill_parent"
    android:layout_height="fill_parent"
    >

    <LinearLayout
        android:orientation="vertical"
        android:layout_width="fill_parent"
        android:layout_height="fill_parent"
        >
    <TextView 
        android:text="Email address(es):"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        />

    <EditText 
        android:layout_height="wrap_content"
        android:layout_width="fill_parent"
        android:id="@+id/etEmails"
        />          

    <TextView 
        android:text="Hatfull intro"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        />

    <EditText 
        android:layout_height="wrap_content"
        android:layout_width="fill_parent"
        android:id="@+id/etIntro"
        />

    <TextView 
        android:text="Persons name"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        />

    <EditText 
        android:layout_width="fill_parent"
        android:layout_height="wrap_content"
        android:id="@+id/etName"
        />

    <TextView 
        android:text="Stupid things this person does:"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        />

    <EditText 
        android:layout_height="wrap_content"
        android:layout_width="fill_parent"
        android:id="etThings"
        />

    <TextView 
        android:text="What do you want to do to this person?"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        />

    <EditText 
        android:layout_height="wrap_content"
        android:layout_width="fill_parent"
        android:id="@+id/etAction"
        />

    <TextView 
        android:text="Hatefull Outro"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        />

    <EditText 
        android:layout_width="fill_parent"
        android:layout_height="wrap_content"
        android:id="@+id/etOutro"
        />

    </LinearLayout>

    </ScrollView>

<LinearLayout
    android:orientation="vertical"
    android:layout_width="fill_parent"
    android:layout_height="fill_parent"
    android:layout_weight="40">

    <Button 
        android:text="Send"
        android:id="@+id/bSentEmail"
        android:layout_width="fill_parent"
        android:layout_height="fill_parent">

    </Button>

</LinearLayout>

<LinearLayout
    android:orientation="vertical"
    android:layout_width="fill_parent"
    android:layout_height="fill_parent"
    android:layout_weight="30">

    <AnalogClock 
        android:id="@+id/analogClock1"
        android:layout_width="fill_parent"
        android:layout_height="fill_parent">

    </AnalogClock>
</LinearLayout>
</LinearLayout>
4

1 に答える 1

2

>6 行目の最後にa がありませんでした:

変化する

android:weightSum="100"

android:weightSum="100">
于 2012-09-02T16:55:36.483 に答える