geoff swartz
geoff swartz

Reputation: 5965

emulator doesn't show my application

I just picked up "Beginning Android 4" by apress and in chapter 3 they have you make your first app. I've gone through it and though a few settings don't match completely (I'm guessing because the android api has been updated since the book was written), it all runs fine. However, the book says I should see the icon for my "Now" project/app in the main menu of apps. It's not there so I'm not sure what might be wrong. Does anyone know if there's a trick to getting it to show up? I'm using the eclipse editor and android plugins. Thanks.

Upvotes: 5

Views: 19662

Answers (4)

theawesomecoder61
theawesomecoder61

Reputation: 35

Try this, this also works.

  1. In Eclipse ADT, go to the Package Explorer, and open the folder called bin.
  2. Now install BlueStacks (http://www.bluestacks.com/), a free Android emulator for Windows/Macs.
  3. Go back to ADT and copy the .apk file in the bin folder to your desktop.
  4. Open BlueStacks and install the .apk file and it should work! :)

Upvotes: 1

superlogical
superlogical

Reputation: 14950

I had this same problem! I was seeing this in the console:

No Launcher activity found!

You need to specify the MAIN and LAUNCHER in the the intent filter for the activity you want to start on launch! There is another stackoverflow answer explaining the solution here.

Basically make sure your AndroidManifest.xml has the MAIN and LAUNCHER arguments specified like this:

<application android:label="@string/app_name" android:icon="@drawable/icon">
    <activity android:name="ExampleActivity"
              android:label="@string/app_name">
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />
            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>
</application>

Upvotes: 5

Soham
Soham

Reputation: 4960

Did you run your application from the emulator? You need to click the 'play' button to get it to run on your emulator and then it should execute on the emulator itself.

enter image description here

Once you do that you should be able to view it in the app drawer of the emulator itself, like so:

enter image description here

Upvotes: 0

TJ Biddle
TJ Biddle

Reputation: 6484

After you create your program, right click on the project and hit Run As > Android Application; this should upload the .apk and install it on your emulator - once that is finished, it will load up.

If it doesn't load up - check what the Console has to say (It's a tab in Eclipse on the bottom) as something could have gone wrong.

Make sure you don't have any red lines in your code - that means there's an error.

Upvotes: 2

Related Questions