In our first tutorial we have learned how to start developing Android application using Eclipse ADT, But after requesting by some of our readers we are writing this post, In this tutorial we will learn How to develop Android application using Android Studio step by step.
After downloading it’s setup double click on it and follow install instruction. After successfully install open Android studio as an application.
First time it will take some time to start, when it started completely click on menu File > New > New Project.
Enter Application name, company domain(if you don’t have company domain just enter ‘com’) and select project location and click on Next button.
Here you can select Application type(Phone/Tablet or TV or Wear or Glass) and their minimum SDK version. Just click Next button if you do not know which is to choose.
After that there is option to add any default Activity Design Select Blank Activity here and click Next button.
In next screen you can edit name of default auto create Activity’s name if you wish.
Then click on finish it will take some moments to create and build project. When Gradle build is finished loading our application is ready to run.
To run our application we need to create an Android Virtual Device (AVD), it will provide us a virtual Android environment to run our applications.
Go to Tools > Android > AVD Manager in Android studio it will open a window. Here we can select any already created AVD to run our application or we can create a new AVD here also. Click on + Create Virtual Device (Bottom left side in this window).
On next screen select any provided Hardware System Device Definition profile or you can create your custom as per your requirement. Here we will select Nexus 5 for our tutorial and click Next button.
On next screen select System Image (Android version for our AVD) and click Next button.
Now give AVD a name and Click finish.(Here you can set Advance Settings like RAM, Storage, etc also.)
Now our AVD is ready and showing in available Your Virtual Devices list. Launch it by clicking on green play icon in Actions tab(Right hand side). We can always edit its configurations by clicking on pencil icon in Actions tab(Right hand side).
First time it will take some time to start AVD.
After it starts we can run our application by clicking menu Run > Run ‘app’ or by pressing a keyboard shortcut Shift+F10.
It prompt us to select a running compatible device to run our application, select created AVD here and wait till our application is uploaded to it.
After process finished we can see that our application is running in AVD.
Please show your interest in comments below and let us know how we are doing here. Thanks for your support.