Creating Android Project
Here we going to create Android project which will display Hello world message.
Enter Clt + N the new resource dialog will open, type Android and select Android Project
New project window will open enter the Project name select the Build target 2.2 or higher . Enter application name and package name.
Eclipse will create project with following structure
Android Project Structure
Src : This folder have all the java files
Gen : This folder contain R.java which is a android generated file . R.java contain id for all of the resources under the ‘Res’ folder which can be used in the java file to access those resources.
Res : Contains project resource files
Drawable : all the images and theme files store in this directory
Layout : This folder contain the xml files which having the screen layout.
String.xml : all the hard coded values are stored in this file. This is use full for multi-language
AndroidManifest.xml : This file have application lever configuration information. This file include declaration of all activities ,Services , User Permission , Screen orientation etc.
The main.xml will have the layout for the display panel which shows the Hello world message. The panel specify the main layout and a Text field in it which display the message.
In the above panel the TextField reading the message from the string.xml file the content of which will be look like bellow.
The Android generated R.java will look like this at this stage.
Android Activity life cycle.
In the above diagram we can see that the onCreate method is the first method to execute. The layout for the activity has to specify in the onCreate method using the method setContentView(). Here you can see that how the android generated R class element used to refer to the resource file.
After completion of project creation we need to run the application , for that we need android AVD(Android Virtual Machine).The Procedure for Creating AVD........follow this
Android AVD
http://adroit-android.blogspot.com/2011/09/android-avd-creation.html