The world has been moving towards mobile and it will be naive of a developer not to acquire skills to develop mobile applications. The most simple and common mobile applications are done in Android. Three of out five uses an android phone. This article and the series concentrate on Android development to a point of publication.
The world has been moving towards mobile and it will be native of a developer not to acquire skills to develop mobile applications. The most simple and common mobile applications are done in Android. Three of out five uses an android phone. This article and the series concentrate on Android development to a point of publication.
The main objective of the part one of this series is to setup the environment. I will also do some introduction to some basic things one needs to know about Android.
Types of Android Applications
Android development has two different types Android Applications. There are hybrids and also native. If you have been following my Series
of developing Android applications, you will notice that the development platforms and tools are not the same.
Hybrid applications act like native and also like website. They are built with html and compile into native. The way they crush if there is an issue they crush like websites. If IIS does not find page it will give the error on the browser. The same error that you see in a webpage is the same error that you will see in a Hybrid application. The hybrid applications take less time to develop as compared to native. Web developer’s transition from web development to hybrid is seamless because the Skills are carried over.
In Hybrid HTML 5 is used as the language to develop the application. The web api or other types of web services are used to move the data between these components. Hybrids have limitations and also the stability is not guaranteed for more complicated applications.
Native applications are built with a solid language like Java, this is for Android. Java is the language of choice. Microsoft Developers also have a chance to develop android applications in C# but the environment is still at its infancy stage and some of the components are not free to use. Native applications are like your Win forms or WPF application if you were to compare them. You know that Windows apps are more stable than web applications. Native application can also consume web services like hybrid does and like hybrid a setup file or installation (.apk) file will be produced at the end.
In this article we will be looking at native application development. If you are familiar with C#, you will not have a problem understanding Java code. The Project arrangement might be confusing at start, but you will get to grip the setup as you working on the IDE of our choice.
IDE (Integrated Development Environment)
There are many IDE’s that one can use to develop Android applications. I will mention only two that are popular
This is an Android IDE build specifically to develop Android applications. This is a new IDE, many people reverted back to older IDE’s because of the problems encountered while using it, but if one spend time on it, it can be a good IDE to use to build Android applications.
This is a popular IDE for Java developers.it is not only used to develop Android Applications like Android studio. This IDE can do all sorts of things. This is an old IDE that has been used throughout the decades. It is the IDE of my choice for now.
Setting up the Eclipse Environment
1) The first step here is to Download Eclipse from this URL
2) Create a Folder named “Eclipse” at C:\Program Files (x86)\
3) After the download is finished, copy the downloaded zip file and open it in your program files folder which is a folder that you normally don’t delete files, the Program files.
4) Unzip the downloaded file.
Eclipse does not have installation file like any other IDE software you normally use. After you copied the files to the Program directory like I did with mine at C:\Program Files (x86)\Eclipse\eclipse-jee-mars-1-win32-x86_64\eclipse
5) There is an executable named eclipse.exe right click and create a shortcut to your desktop so that you will open the IDE.
SDK (Java Development Toolkit) setup
Before one can develop android applications on any IDE’s one need to have the Android sdk installed. To download the sdk please follow the link
After you have downloaded the sdk, you will store it also in a safe directory, as I suggested above, I normally store it in the Eclipse directory in the Program Files folder as depicted in figure 1.1
After you have copied the sdk to the location of your choice, view the folder contents and look for the SDK Manager as depicted in figure 1.2
And when the sdk manager opened, you will see a window like mine, but because I have already downloaded the android sdk for varies versions, it will say installed as depicted in Figure 1.3
You can select any version of Android that you want to target and click “Install Packages” at the far bottom right of your SDK Manager window. This Process might take a long time, so you might want to select all the Versions of Android that you want to target and at the Bottom of the Windows there Extra’s and Google USB Driver, that one you might want to select if you want to debug from your android phone instead of using an Emulator which is very slow to show and can be annoying if you are debugging or developing. You can take a walk to a Park while its downloading as this can take the whole day depending on your needs.
After the Android sdk is installed and all the version that you wish to target are complete, you can now open the Eclipse IDE, and start familiarizing yourself with it. In the next IDE, I will cover the basics of the Eclipse IDE, where to find what you need.