Today I am going to start with How to make a Simple Application in Android. Before Starting It we must be clear about some aspects related to Android Development. As We already know now from previous post about Setting up of Android SDK with Eclipse. So We will uncover the basic file hierarchy of Android App.
Starting of Android Application.
- Open Up your Eclipse. Then go to File - > New Project - > Android Project. A dialog box will be opened up as shown.
New Android Project |
- Now you have to fill some details. Like Project Name, Project Location. After Clicking Next you will be asked to Select for API version. Select According to your requirement.
- After then Enter Package name like if your application name is sample. Then Package can be com.simple. Check for Activity automatic creation as it is needed. After finishing Project is now created and you will have a hierarchical view just like below (if we have created application named test).
Hierarchical View of Application |
Various Files In Android
- src :- This folder contains the main core Activity file for the application being created. And the major work of coding goes into this folder.
- gen:- These are automatic generated configuration file that will be used by the system.
- res:- The Main designing part goes here in this folder. Here in various folders like drawable-hdpi and similar named folders hold the various images to be used by the application. Next it contains the folder layout where you will be defining the layout for different views of your application.
- values:- This sub folder of res holds the different string.xml and other files for handling the data that will be referred in time to time in the application that is being developed.
- AndroidManifest.xml will hold the values like the permission granting for internet access and some other system related requirements that will be additional.
Project Development
TestActivity is the file in case of application test where we will be spending most of our time in performing coding. The pre generated code for this particular file is as below. (Remember Android Programming is nothing but JAVA programming with API's and Android Additional services.)
So, If one knows java it is not going to be difficult to learn AP (Android Programming).
So in the next post we will come to the actual coding of this test application. Till then Good Byee!!