我越来越没有找到活动错误 [英] I am getting activity not found error

查看:211
本文介绍了我越来越没有找到活动错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我得到了异常活动未找到.I've命名的活动:

I'm getting an Exception "Activity Not Found".I've an activity named:

public class ProfileForm extends Activity implements View.OnClickListener.

,并在的Andr​​oidManifest.xml 我宣布本次活动:

<activity
            android:name="com.atria.requisitionform.ProfileForm"
            android:label="Profile Form Activity" >
        </activity>

有人可以请帮助解决这个?因为这样的例外的,我得到一个消息,不幸的是应用程序已关闭错误。

Can someone please help resolve this? Because of this exception I'm getting a message"Unfortunately application has closed" error.

推荐答案

再配置清单文件使用该code和修改活动名称。

again config your manifest file use this code and change the activity name.

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

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

    <application
        android:allowBackup="true"
        android:icon="@drawable/ic_launcher"
        android:label="@string/app_name"
        android:theme="@style/AppTheme" >
        <activity
            android:name=".MainActivity"
            android:label="@string/app_name" >
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />

                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>
    </application>

</manifest>

这篇关于我越来越没有找到活动错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆