Android cannot open the app

I created an .apk for a small application that I wrote for android. On the completed installation screen, the "Open" option is grayed out and cannot be selected. After I search for the device for the application, the icon does not appear, if I check the installed applications, it is there but still does not open. I believe this is a problem with androidmanifest.xml. I have very little experience with androidmanifest and mostly just work with java.

<application

    android:allowBackup="true" android:label="@string/app_name"
    android:icon="@mipmap/ic_launcher" 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="andriod.intent.category.LAUNCHER"/>
            </intent-filter>







        </activity>





</application>

      

Above is my manifesto, I understand that my manifesto probably has a lot of errors, so thanks for your help and patients in advance.

+3


source to share


3 answers


Default assignment to run:



    <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>

      

+2


source


it's a typo?

intent-filter>
      <action android:name="android.intent.action.MainActivity"/>
        </intent-filter>

      



it should be like this

<intent-filter>
            <action android:name="android.intent.action.MAIN" />

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

      

+2


source


Your intent filter is wrong, so the reason why android is not rendering the icon. Just search for a quick google search or create a new project and copy the intent filter from the manifest.

+1


source







All Articles