views:

25

answers:

1

I have an app that i am working on. but when i run it through the eclipse avd... It shows two icons in the app screen. any ideas what is going on?

Also I used the apk to install on my phone and i also saw two installation of the same app on my phone.

+1  A: 

you have to set a one Launcher activity in your manifest. that is

you set it as:

<activity android:name=".Activity1" android:label="@string/appname">
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>
        <activity android:name=".Activity2" android:label="@string/appname">
            <intent-filter>
                <action android:name="android.intent.action.VIEW" />
                <category android:name="android.intent.category.DEFAULT" />
            </intent-filter>
        </activity>

you have to put the <category android:name="android.intent.category.DEFAULT" /> instead of <category android:name="android.intent.category.LAUNCHER" /> for your the activity you dont want to launch.

Praveen Chandrasekaran
if this isn't the case then he must have renamed the package
schwiz
Thank you. that did the trick.
Will