我的应用程序收到错误"不幸的是,App停止了。"我每次加载它

时间:2014-04-20 08:03:12

标签: java android runtime-error

我最初尝试在我的应用中添加一个启动页面,并按照如何操作的教程进行操作。但是,现在每次加载我的应用程序时,它都会在白色屏幕上显示几秒钟然后再说#34;不幸的是,[App]已停止。"

我无法找到复制LogCat的方法,所以这里出现了错误的图像:

enter image description here

此外,这是我的Manifest XML:

<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="com.bipbapapps.leagueclickerapp"
    android:versionCode="1"
    android:versionName="1.0" >

    <uses-sdk
        android:minSdkVersion="8"
        android:targetSdkVersion="19" />


    <application
        android:allowBackup="true"
        android:icon="@drawable/ic_launcher"
        android:label="@string/app_name"
        android:theme="@style/AppTheme" >

        <activity
            android:name=".Splash"
            android:label="@string/app_name">
                <intent-filter>
                    <action android:name="android.intent.action.MAIN" />
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>

        <activity
            android:name=".MainClass"
            android:label="@string/app_name">
                <intent-filter>
                    <action android:name="com.bipbapapps.leagueclicker.CLICKER" />
                <category android:name="android.intent.category.DEFAULT" />
            </intent-filter>
        </activity>

    </application>

</manifest>

从清单中删除启动Java和活动现在没有任何帮助(当我删除它时,我确实将MainClass还原为.LAUNCHER。

任何人都可以理解这个列表,和/或帮我再次运行我的应用程序吗?

3 个答案:

答案 0 :(得分:0)

从日志中,我发现你应该

requestFeature

之前致电setContentView();

答案 1 :(得分:0)

错误表明您在setContentView()之前呼叫requestFeature()。不要这样做。

答案 2 :(得分:0)

LogCat应该会向您显示问题。单击LogCat中的所有错误行,直到您被重定向到问题。

我,我自己,发现你的问题可能在:Splash.java,第19行

去看看,希望它有所帮助!