1

This is my AndroidManifiest.xml File Their is 2 error no resource identifier found for attribute 'launchmode' in package android no resource identifier found for attribute 'stateNotNeeded' in package android

  <?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="a52.puri.fbkunal.com.launcher">

    <application
        android:allowBackup="true"
        android:icon="@mipmap/ic_launcher"
        android:label="@string/app_name"
        android:supportsRtl="true"
        android:theme="@android:style/Theme.Wallpaper.NoTitleBar.Fullscreen"
        android:launchMode="singleTask"
        android:stateNotNeeded="true"
        android:
        >
        <activity android:name=".MainActivity">
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />

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

            <intent-filter>
                <action android:name="android.intent.action.MAIN" />
                <category android:name="android.intent.category.DEFAULT" />
                <category android:name="android.intent.category.HOME" />
            </intent-filter>
        </activity>
    </application>

</manifest>
IntelliJ Amiya
  • 74,896
  • 15
  • 165
  • 198
Kunal Puri
  • 185
  • 1
  • 9
  • Possible duplicate of [error: No resource identifier found for attribute 'adSize' in package 'com.google.example' main.xml](http://stackoverflow.com/questions/5819369/error-no-resource-identifier-found-for-attribute-adsize-in-package-com-googl) – nobalG Feb 25 '17 at 05:16
  • Why the last attribute of your `application` tab half eaten? (`android:`) – Kamran Ahmed Feb 25 '17 at 06:01

2 Answers2

1

Assign a launchMode into Activity not in application tag. Basically we could assign a launchMode directly as an attribute of <activity> tag inside AndroidManifest.xml file list this:

<activity
    android:name=".SingleTaskActivity"
    android:label="singleTask launchMode"
    android:launchMode="singleTask">
Mr Lister
  • 45,515
  • 15
  • 108
  • 150
Chetan Joshi
  • 5,582
  • 4
  • 30
  • 43
1

You are assigning unknown property for application tag, launchMode in android is for Activities. Activities launch and visible to user but Application launch only once when you start your App. You can say Application is a start point in Android App.

Rahul
  • 10,457
  • 4
  • 35
  • 55