Skip to main content

Cannot Choose Between Multiple Debugging Devices in Android Studio

If  you connect multiple Devices or Emulators to Android Studio and Run Application. Application will only run on the first run device.  It will not ask to select connected device.
ie,
1. If you connect one Device or Emulator
2. Run a project on the device or Emulator
3. Connect another Device or start another Emulator
4. Try to run project on new device
5. It will only run on first device  . will not ask to select Connected Device or Emulators
6. Select Deployment Target Dialog box will not show.

If this Problem occurs to you while Developing on android Studio .  First thing to do is to



  • Stop Application after running on the first device
  • This can be done by clicking Stop app icon which is left of the AVD manger icon.
  • Or by using Keyboard shortcut CTRL+F2
  • Now if you Run the project , Select Deployment Target Dialog box will pop up.
  • You can select another Device or emulator from the list
If still Select Deployment Target window not showing up and project runs on the first device . it will be due to problem with your Run Configuration
  • Go to Run --- Edit Configurations
  • In the General Tab look for Deployment Target Options
  • in that select "Open select Deployment Target Dialog" for target
  • Uncheck  "Use same device for future launches"




this will solve your problem😊

Now if you Run your Application deployment target Dialog will show. then select the device you need




Comments

Popular posts

Android CardView And SQLite example

SQLite Database Android provides several options to save persistent application data. SQlite database is ideal for saving repeating and structured data . Using Sqlite we can save structured data in a private database.  This is a simple application showing use of Sqlite database in android . This example shows how to perform Insert , select , update and delete operation in  SQlite database Screenshots of our sample application                                                                                                                      This is a Registration app. New user can register by clicking registration button . Registered  users are shown in cards below that button . we can update or delete registered users by clicking overflow menu in each card. 1.First we need to create database for our application .    a. Create a contract class .Contract class contains constants that defines names of Tables and columns of our database. Contract class allows us

Android List View using Custom Adapter and SQLite

following is a simple applicaton to create ListView using  Custom adapter.screenshot of the application  is like this . ListView is not used in android Anymore . We use  RecyclerView  and  CardView   in Android RecyclerView Demo is available on the following link http://androidtuts4u.blogspot.in/2017/04/android-recyclerview-example.html RecyclerView with Cardview Example is available on the following link http://androidtuts4u.blogspot.in/2017/09/android-card-view-example.html The ListView below the submit button is populated using Custom Adapter.Data is stored and retrieved using SQLite databsase. you can download the source code of this project from  google drive   https://drive.google.com/folderview?id=0BySLpWhqmbbdUXE5aTNhazludjQ&usp=sharing click on the above link ->sign into  your  google account ->add this to your google drive -> open it in google drive and download it. To create a simple application like this 1.  Create a class which extends  

Google Sign-in for Android App

This is demo application implementing Google Sign-in in android application. Screenshots of the application are when you click on the sign in button popup will be shown to select google account for sign in . After signing in , user can see his profile photo,name and Email id in the login screen . User can sign out using signout button . Disconnect button will provide user ability to disconnect their google account from the app. Before we start coding for our application , we need to turn on sign-in API for our app in google developer console. Go to this link to know  how to turn on google sign-in api for our app https://androidtuts4u.blogspot.com/2019/09/enabling-sign-in-api-in-google.html now we successfully configured Google Api console project .  we can start coding our application. I . first we need to configure build.gradle file we need to add two dependencies   1. google play service dependency for google sign-in.    2 . we are using third party library