Android 应用程序显示没有错误,但崩溃

Android 应用程序显示没有错误,但崩溃,android,crash,Android,Crash,我对编程还是相当陌生的。 我正在开发一个练习应用程序,每当我尝试运行它时,它就会崩溃。我尝试将代码主体移动到不同的应用程序模板,但仍然崩溃。我试着在一个正常工作的应用程序中用它代替代码,但失败了。我确信这是代码中的一些东西,我迫不及待地想知道是什么。提前感谢大家的帮助。 -约瑟夫 这是我的密码 <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://sche

我对编程还是相当陌生的。 我正在开发一个练习应用程序,每当我尝试运行它时,它就会崩溃。我尝试将代码主体移动到不同的应用程序模板,但仍然崩溃。我试着在一个正常工作的应用程序中用它代替代码,但失败了。我确信这是代码中的一些东西,我迫不及待地想知道是什么。提前感谢大家的帮助。 -约瑟夫 这是我的密码

<RelativeLayout 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"
tools:ignore="contentDescription">
    <ImageView
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:src="@drawable/goliath2"
        android:scaleType="centerCrop"
        android:id="@+id/imageGoliath"/>
    <TextView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:text="Hello, I'm Goliath."
        android:textColor="#C62828"
        android:textSize="36sp"
        android:fontFamily="sans-serif-medium"
        android:textStyle="bold"
        android:id="@+id/ImGoliath"
        android:layout_centerInParent="true"
        android:layout_alignParentTop="true"
        android:padding="12dp"/>
    <TextView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:text="Don't be afraid, I don't bite..."
        android:textSize="26sp"
        android:fontFamily="sans-serif-medium"
        android:textColor="#C62828"
        android:id="@+id/afraid"
        android:layout_below="@id/ImGoliath"
        android:textStyle="bold|italic"
        android:paddingLeft="12dp"
        android:paddingBottom="18dp"/>
    <TextView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:id="@+id/unless"
        android:text="Unless!"
        android:textColor="#C62828"
        android:textSize="52sp"
        android:textStyle="bold"
        android:layout_alignParentEnd="true"
        android:layout_alignParentRight="true"
        android:layout_below="@id/afraid"
        android:padding="24dp"/>
    <TextView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:id="@+id/Youreacricket"
        android:text="YOU'RE A CRICKET!"
        android:textColor="#C62828"
        android:layout_alignParentBottom="true"
        android:textSize="42sp"
        android:textStyle="bold"
        android:layout_centerInParent="true"
        android:paddingTop="60dp"/>


我的问题可能是图像文件太大。 在用我在课堂上得到的androidparty图像替换图像后,应用程序运行良好。
感谢所有试图提供帮助的人。

如果它崩溃,stacktrace中会出现异常。你需要贴出来寻求帮助。此外,您在发布的xml(
)中缺少终止的结束根标记。可能只是复制/粘贴错误。谢谢,缺少()是复制/粘贴错误。版面工作了。你说的“版面工作了”是什么意思?我调整了图像大小,可以运行应用程序了。