tags:

views:

209

answers:

4

Whenever I run my app I get the Android Device Chooser dialog:

alt text

This is happening because I am using the Google APIs for 1.6 and trying to run the application on my Nexus one. Is there any way to make this automatically, or to not check the compatibility? Sometimes when I make a modification and quickly after I save and run the application, Eclipse will build the project and the Android Device Chooser dialog will show briefly and disappear and the app won't run. I have to click run again for it to work. Any workarounds?

+1  A: 

Create a run configuration.

Run -> Run Configurations.

Select your project and specify your target and from then on run that configuration when you run that app.

Ravi Vyas
This option only allows me to set it up for a Virtual Device. I can't see an option for a real device.
janfsd
A: 

Just set the 'target' tab to the 'Automatic' option and it will launch on your device automatically.

roundhill
It is on automatic. It was fine before adding the Google Maps API, now it shows the dialog all the time.
janfsd
+1  A: 
Pentium10
I had this already. The Android Device Chooser dialog only shows for the project that has included Google Maps API and when developing on the actual device. For the rest of the projects without that API it doesn't show.
janfsd
Ok this problem seems fixed in 2.2. So I would mark this as the answer since it fixes the quickly dismissing device chooser dialog problem, so if that happens, the app will start on the device. Strange that the problem only happpens with 2.1. Tested with a G1 and no problems at all. At least upgrading to Froyo fixed this :)
janfsd
A: 

So have you got any solution for hiding the Android device chooser when using Google Maps API ?

sazwqa
Using 2.2 and setting the automatic options as in the selected answer hide the Android device chooser *most* of the times, at least in my case.
janfsd
I'm also getting this option when using the Google APIs, just selecting the Android 2.2 libraries launches automatically. Do you have any updates?
Luca Spiller
No updates as of now.
sazwqa