Sunday, September 16, 2012

CHAPTER 2 - Your First App - Getting to know the Android Environment (PART 1)

   Here is a small tutorial to get starting on developing Android applications with Eclipse.  It is the really simple and everyone who was introduced to Android development is probably familiar with it.  This section will help you understand how the android development environment works.  After finishing you should have a basic understanding of Android. 



GETTING STARTED WITH ECLIPSE AND ANDROID

 After finishing installing the eclipse plugin then your Development environment should be set to start.   It may be intimidating and if you encountered problems updating the Eclipse environment like I did then you should be glad it is done.  

REQUIREMENTS

  • Android SDK
  • Eclipse
  • ADT Plugin for Eclipse Version 20.0.0 or higher.  
  • Basic Knowledge of Windows

STARTING A PROJECT WITH ECLIPSE


  1. Start up Eclipse
    1. Click on New Android App Project which should be visible after installing the Eclipse Plugin.
  2. Fill in the form that appears
    1. Application Name = App name that will appear to users
    2. Project name = name of the directory in which the project will be saved
    3. Package Name = Name of the package that follows the same naming conventions associated with the Java programming language
      1. Naming the package is important because it must be different than all the other applications submitted to the android marketplace
      2. Google recommends you use the com.somewebaddress.nameoftheapp all in lowercase letters.  It works quite efficiently in order to distinguish the many different apps in the store.
    4. Build SDK = After installing the different SDK's with the Android Development Manager then you should be able to see the versions of the android operating system that you downloaded in this drop-down menu.  Android 2.3.3 seems to be the most popular version as of 2011.  
    5. Minimum Required SDK = The minimum required Android version to run the application you are developing.  You will have to choose this carefully as there are previous versions of android that don't have the offer the features of the newer ones.  It is better to leave this value as is.
  3. Click NEXT
  4. On this screen you can configure your own launcher icon.  It is the icon that will appear on your android phone or tablet so you can tap on it and start it up.  Since there are different types of android screen sizes Google has provided different icon sizes. 
  5. The next screen lets you select which templates you can use to design your app
    1. Since this is your first app just click on Blank Activity and then click.
  6. Click NEXT.
  7. Just leave all the default values on this screen.
  8. Click NEXT.  
  9. Your android project is now ready and you should be taken the Eclipse development environment where you can see all the different components that android uses.  It is a really simple environment that relies on Graphical User Interfaces in order to facilitate programming.  
The Android SDK also lets you create your own projects from the command prompt.  It is almost as easy as using the method above and someday it you may actually need it.   

No comments:

Post a Comment