বুধবার, ২৯ সেপ্টেম্বর, ২০১০

Android

Eclipse installation guide for Android on Windows XP

Technical requirements:

  1. 32-bit Windows® XP, Windows Vista™ or Windows 7 (Note: 64-bit versions require 32-bit Java and Eclipse)

  1. Monitor with a resolution of 1024 x 768 or higher PC with Intel® Pentium® 4 processor or compatible (2.5 GHz or higher, 2 GB RAM, 1.5 GB HD free)

  1. jdk-6u17-windows-i586.exe

  1. android-sdk_r04-windows.zip

  1. eclipse-java-galileo-SR1-win32.zip
  2. ADT-0.9.5.zip
  3. Platforms4Android.zip

Installation Steps:

  1. Please disconnect your PC from internet.
  2. Install jdk-6u17-windows-i586.exe to C:\Program Files\Java\

  1. Create a folder (for example Eclipse4Android) to a local drive (for example E drive).

  1. Extract eclipse-java-galileo-SR1-win32.zip in E:\ Eclipse4Android\

  1. Extract android-sdk_r04-windows.zip in E:\ Eclipse4Android\

  1. Extract Platforms4Android.zip in E:\ Eclipse4Android\

  1. Copy ADT-0.9.5.zip in E:\ Eclipse4Android\

  1. Now lunch eclipse.exe from E:\Eclipse4Android\eclipse-java-galileo-SR1-win32\eclipse

  1. While lunching eclipse.exe it requires a workspace directory to save projects in it. Create a directory as your wish (for example E:\AndroidWorkspace).

  1. After lunching eclipse.exe click on help à Install New Software à Add à Archive

  1. Then link the location E:\Eclipse4Android\ADT-0.9.5.zip

  1. Click OK button of Add Site window.

  1. Select --Only Local Sites-- from dropdown list.

  1. Check the box Developer Tools and click Next button of Install (Available Software) window.

  1. Click Next button of Install (Install Details) window, accept the license agreement and then click Finish button.

  1. Wait until the installation is completed and restart the system (here system means eclipse not the machine) if requires by clicking Yes button of Software Updates pop up window.

  1. Click Close button of Software Updates and Add-ons window.

  1. Now click on Window à Preferences à Android.

  1. Browse the SDK Location E:\Eclipse4Android\android-sdk-windows, click Apply and then OK.

  1. Copy android-2.0.1 and android-2.1 to E:\Eclipse4Android\android-sdk-windows\platforms from E:\Eclipse4Android\Platforms4Android.

  1. Now click on Window à Android SDK and AVD Manager, select Virtual Devices and click New.

  1. In the Create new AVD window give a name (for example AndroidAVD), select a target (for example Android2.0.1-API Level 6) and finally click Create AVD.

  1. Click OK of Android Virtual Devices Manager window.

  1. Close the Welcome window.

Screen 1


Screen 2

Screen 3

  1. My Computer à Properties à Advanced à Environment Variables (Screen 2)

  1. Select Path and click Edit (Screen 3)

  1. In the Variable values field add the paths of jdk\bin, jre\bin and android-sdk-windows\tools separated by semicolon (C:\Program Files\Java\jdk1.6.0_17\bin;C:\Program Files\Java\jre6\bin;E:\Eclipse4Android\android-sdk_r04-windows\android-sdk-windows\tools)

  1. Now eclipse is ready to create and run your BlackBerry project.

import android.app.Activity;

import android.os.Bundle;

import android.widget.TextView;

public class AndroidTest extends Activity

{

/** Called when the activity is first created. */

public void onCreate(Bundle savedInstanceState)

{

super.onCreate(savedInstanceState);

TextView tv = new TextView(this);

tv.setText("Hello, this is Android Test");

setContentView(tv);

}

}