Last updated on May 8th, 2017 at 01:53 pm
Write your first Android App, will be really easy with these simple steps.
Required Android Studio
Create a new project
From the Start menu launch Android Studio
When you start on Welcome Menu select Start new Android Studio project
In order to build a new project we have to choose
- Application name: The name of our app, it will also be displayed on the device and in the Play Store
- Company domain: it could be the name of our company, or a mnemonic name of our project
- Package name: represents the full namespace
- Project location: indicates the physical directory for saving the entire project developed with Android studio
Continuing with next you have choice of the distribution platform, for which device we want to make our app available, such as Phones and Table, Watches, TV etc ..
Select on the left what kind of platform you want to distribute the app, in this case Phone or Tablet
Selected the target, it’s time to choose whether to start using an existing preset template App, or you want to start from scratch. For simplicity we will use Basic Activity
The last step is the customization for names to use in our Activity, Menu and Layout.
- Activity name: indicates the class name to the Activity that is being created
- Layout name: indicates the name of the XML file that will serve as a layout for our GUI
- Title: indicates the title of this Activity
- Menu Resource Name: the name of the XML file to be created, by using the menu
Continuing with Finish your new app will be created.
UOnce the app is ready we can test it on either a actual device or in the emulator made available by Android Studio.
To configure an emulator you have to choose from the top menu, ADV Manager, here we can set up new testing environments, useful if you want to test various devices with different sizes and resolutions.
We start the emulator using the green button Play
During the installation may not have been installed HAXM, so if it should appear the following message, simple press OK.
Choose the amount of RAM memory that you want to assign to the emulator and click Next.
Run your first App
At this point you can test our first app.
From the main menu select the green Play symbol, from the target list, select as a device, one on which you want to test the app, here you can choose the same name of emulator or real name of your phone, if it is connected in USB, then click OK
Within a few seconds the app will start automatically on the device
Congratulations you have write your first Android App.