Katherine99
Katherine99

Reputation: 990

Activity Not Found Exception (Activities declared and running perfectly before)

I had an app with several activities running perfectly until I added a new activity, which became the launch activity. Now, the app stars in that activity but when I go to another activity it says Activity Not Found Exception even the activities are declared.

Here is my manifest, as I do not know what I am missing.

  <application
        android:allowBackup="true"
        android:icon="@drawable/ic_launcher"
        android:label="@string/app_name"
        android:theme="@style/AppTheme" >
        <activity
            android:name="com.example.visualizacion.Menu"
            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=".com.example.cuestionario.Page1"
                    android:configChanges="orientation"
                     android:screenOrientation="sensorLandscape"></activity>
         <activity android:name=".com.example.cuestionario.Page3"
                    android:configChanges="orientation"
                     android:screenOrientation="sensorLandscape"></activity>

        <activity android:name="com.example.cuestionario.Page2"
                    android:configChanges="orientation"
                     android:screenOrientation="sensorLandscape" ></activity>

              <activity android:name="com.example.cuestionario.Page4"
                    android:configChanges="orientation"
                     android:screenOrientation="sensorLandscape" ></activity>
                 <activity android:name="com.example.cuestionario.Page5"
                    android:configChanges="orientation"
                     android:screenOrientation="sensorLandscape" ></activity>
                      <activity android:name="com.example.cuestionario.Page6"
                    android:configChanges="orientation"
                     android:screenOrientation="sensorLandscape" ></activity>
                       <activity android:name="com.example.cuestionario.Page7"
                    android:configChanges="orientation"
                     android:screenOrientation="sensorLandscape" ></activity>
                       <activity android:name="com.example.visualizacion.Page1C"
                    android:configChanges="orientation"
                     android:screenOrientation="sensorLandscape" ></activity>
                       <activity android:name="com.example.visualiacion.Page2C"
                    android:configChanges="orientation"
                     android:screenOrientation="sensorLandscape" ></activity>
    </application>

When I go from Menu (Launcher Activity) to another activity it crashes with that exception.

Thank you

Upvotes: 0

Views: 105

Answers (1)

Anurag Tyagi
Anurag Tyagi

Reputation: 1329

Check package path of your classes declared in Android Manifest and remove .(dot) from full class name. for Page1 and Page 3. i.e

android:name=".com.example.cuestionario.Page1"

and

android:name=".com.example.cuestionario.Page3"

Upvotes: 2

Related Questions