`

android学习笔记-1-环境搭建

阅读更多
1.安装JDK1.6,Eclipse3.6

2.安装android SDK http://developer.android.com.nyud.net/sdk/index.html

3.安装Eclipse插件 ADT(android development tool)
   1. Start Eclipse, then select Help > Install New Software....
   2. Click Add, in the top-right corner.
   3. In the Add Repository dialog that appears, enter "ADT Plugin" for the Name and the following URL for the Location:

      https://dl-ssl.google.com/android/eclipse/

      Note: If you have trouble acquiring the plugin, try using "http" in the Location URL, instead of "https" (https is preferred for security reasons).

      Click OK.
   4. In the Available Software dialog, select the checkbox next to Developer Tools and click Next.
   5. In the next window, you'll see a list of the tools to be downloaded. Click Next.
   6. Read and accept the license agreements, then click Finish.
   7. When the installation completes, restart Eclipse.

4.Adding Platforms and Other Components
   # From within Eclipse, select Window > Android SDK and AVD Manager.
   # On Windows, double-click the SDK Manager.ext file at the root of the Android SDK directory.

5.创建AVD(android virtual device)
To create an AVD:

   1. In Eclipse, choose Window > Android SDK and AVD Manager.
   2. Select Virtual Devices in the left panel.
   3. Click New.

      The Create New AVD dialog appears.
   4. Type the name of the AVD, such as "my_avd".
   5. Choose a target. The target is the platform (that is, the version of the Android SDK, such as 2.1) you want to run on the emulator.

      You can ignore the rest of the fields for now.
   6. Click Create AVD.

6.创建android项目 hello world
   1) From Eclipse, select File > New > Project.
   2) Select "Android Project" and click Next.
   3) Fill in the project details with the following values:

    * Project name: HelloAndroid
    * Application name: Hello, Android
    * Package name: com.example.helloandroid (or your own private namespace)
    * Create Activity: HelloAndroid

      Min SDK Version:这个值和API等级一致,如:9
        This value specifies the minimum API Level required by your application.

分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics