Make Your Very Own " hello world " app


Setting up the Android Development Environment

We will be using the Android Software Development Kit (SDK) that comes pre-packaged with
Eclipse, a full-featured Integrated Development Environment (IDE) which we will use to write
and run our Android applications. Follow the three steps below to set up your system. Only Step
1 is platform dependent, Steps 2 & 3 are designed for any of the 3 major systems
(Windows/Linux/Mac OS X).


1. Install Java 6 JDK


Windows/Linux :
Download the installer appropriate for your system from the following web page:
       1877406.html

Max OS X (10.7):
Your system may already have a JDK installed. To determine if you have a JDK installed, open
Terminal and run the command ‘javac’. If you do not have a JDK installed, a prompt will pop
up asking if you wish to install one (do so). If you do have a JDK installed, the help prompt for
the javac program will be displayed.


2. Install Android SDK

Click the “Download the SDK” button from the following link to download the SDK:
      ● Windows/Mac OS X/Linux: http://developer.android.com/sdk/index.html
After downloading the file, extract/unzip it to wherever you like. The IDE we will be using to write
Android applications is called Eclipse, and is located in the adt-bundle-.../eclipse/
directory (where adt-bundle-... is the directory where you unzipped the Android SDK file).

3. Install the ADT Plugin for Eclipse

Follow the steps outlined in the following link:




Testing the Environment:

To test the setup, we will create and run a simple Hello World application.

1. Create a new Android Application:

File > New > Android Application, fill in a name and continue hitting ‘Next‘ and then ‘Finish’



2. A Hello World program will be created for you now by default. To build and run the program,
click the ‘Run’ button (see below).






3. You will now be asked to select which device to program. Click the ‘Manager’ button to open
up the Device Manager. We will use the Device Manager to configure an emulator which we will
use to run the Android application





4. In the window that appears, click the ‘New’ button on the right-hand side. A new window will
open, asking you to configure the emulator. Configure the device as shown in the image below.
When you are finished configuring it, hit ‘OK’.




5. Close the remaining windows until you see the window named ‘Android Device Chooser’ (see
image below). After hitting the ‘Refresh’ button, you should be able to select your newly-created
emulator for running the application. Select the device and hit ‘OK’.

6. The emulator will now launch and boot up (this will take a few minutes depending on the
speed of your machine). After booting up, it will launch the Hello World application we just
created:

for more information read this book in the link below

share it and enjoy it 

Comments