开发者

Error in AndroidManifest.xml file !

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
      package="org.example.sudoku"
      android:versionCode="1"
      android:versionName="1.0">
    <application android:icon="@drawable/icon" android:label="@string/app_name">
        <activity android:name=".Sudoku"
                  android:label="@string/app_name">
            <intent-filter>
                <action android:nam开发者_JAVA百科e="android.intent.action.MAIN" />
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>
  //error here->//      <activity android:name=".about"
        android:label="@string/about_title">


</activity>

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

</manifest> 

//Th problem is ,when I was developing a sudoku game I got an error in defining the activity (.about). Above I have written the code and the place where the error occurred. Please help//


I see nothing strange. Could it be that you where trying for ".About" instead of ".about" ?


Some things to check:

  • About starts with capital letter as Nanne said.
  • About should be in package org.example.sudoku.
  • About should extend Activity.

Also notice that instead of doing:

<activity android:name=".About"
        android:label="@string/about_title">
</activity>

You can do:

<activity android:name=".About"
        android:label="@string/about_title"/>


Try this code:

<activity
    android:label="@string/about_title"
    android:name=".About"
    android:theme="@android:style/Theme.Dialog"
    />
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜