0

i am getting this error i have tried everything invalidating caches restarting and even editing the config. to main directory when doing this it is giving error .MainActivity not declared in manifest any help would be appreciated and this error is coming from the moment i pulled my code with my friends code working on same project using github

<application
        android:allowBackup="true"
        android:icon="@mipmap/ic_launcher"
        android:label="@string/app_name"
        android:roundIcon="@mipmap/ic_launcher_round"
        android:supportsRtl="true"
        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>
        <activity android:name=".ProductDescriptionActivity"/>
        <activity android:name=".ForgetPassOtp"/>
        <activity android:name=".ForgetNumber" />
        <activity android:name=".ResetPassword" />
        <activity android:name=".VerifyPhone" />
        <activity android:name=".RegisterActivity" />
        <activity android:name=".LoginActivity" />
        <meta-data
            android:name="preloaded_fonts"
            android:resource="@array/preloaded_fonts" />
    </application>

</manifest>
ʍѳђઽ૯ท
  • 16,646
  • 7
  • 53
  • 108
  • 1
    Please check for the package names to match at all places. The manifest file, build file and source files should be in the same structure of the package name. Clean the project and then rebuild it. Try uninstalling any previous application from the emulator/device which you are using to debug the app. Once the source code is build again, try and run it again. – Atish Agrawal Jul 21 '20 at 10:06

1 Answers1

0

Try Invalidate Caches / Restart...

File -> Invalidate Caches / Restart...

possible duplicate "Default Activity Not Found" on Android Studio upgrade Default Activity Not Found - Bug in Android Studio 3.3

Jyotish Biswas
  • 674
  • 5
  • 11