Android :Learn to make your own Android App

Android applications are in great demand in the market ,and that how it attarcts more freaky programmers to develop apps for Android. Today ,I am going to demonstrate how to display any text in the Android App .

If you are newbie to Java,then this is not the right place for you,just brush up Java before you start here.At first you need to install Android SDK as per your system.For installation help click here

STEP 1: Start Eclipse.Once it is started.Go to File

File->New->Android Application Project.


A dialog box will appear ,name is whatever you wish like i have given it name as Android_1
If you are asked to select a build target,and if you have installed Android API,choose API level as shown in the picture below.
android 4
Once selected click Next.
NOTE: The name of the package should be unique as once you will upload this app to Google Android marketplace.You Android App will be recognized with unique package name.

STEP 2: Now we need to create an activity.Activity is basically the layout structure that we want to display in our App.
Select Blank Activity on clicking next after Step 1.
Give the name of the Activity as I have given the name of the activity as Android_test
and click Finish
a6-03-15 12:03:36

FInally go to Window->AVD Manager and start your target emulator( An emulator is a virtual Android device to run Android Apps ).

STEP 3: Go to ECLIPSE  and see the Project Explorer ,and you will see all the files  listed in your project like the following image.


Now open AndroidManifest.xml and you will find the codes as

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android=""
    android:versionName="1.0" >

        android:targetSdkVersion="17" />

        android:theme="@style/AppTheme" >
            android:label="@string/app_name" >
                <action android:name="android.intent.action.MAIN" />

                <category android:name="android.intent.category.LAUNCHER" />

        <activity android:name=".Second_activity" android:label="@string/app_name"/>



Brief Explanation about AndroidManifest.xml:-

AndroidManifest.xml file contains app specific settings such as app version and minimum SDK version.The different permissions required,activities that can be run,services,broadcast receives and more.
Once open,it will open in default graphical view,change it into AndroidManifest.xml view at the bottom right of your view of the manifest .
At the top level under application you are specifying icons and label.The main function of intent filter stuff is that it specifies what should launch when an App runs.

And again go to project Explorer and search for “res” folder and res->values>string.xml and the string.xml will open like shown below .

<?xml version="1.0" encoding="utf-8"?>

    <string name="app_name">android_1</string>
    <string name="hello_world">Hello world! THIS IS MY ANDROID TUTORIAL</string>
    <string name="menu_settings">Settings</string>
     <string name="test_one"> THIS IS MY FIRST ANDROID PROGRAM</string>
     <string name="click_me">Click Me</string>


you will see that two strings are already created.If you look at the AndroidManifest.xml file ,you will find
@String/app_name.It is referring to the app_name string seen here.This string.xml is basically a resource file.These are heavily used in Android to make it easier to localize your application.
Again move on to res/layout/activity_android_test.xml.You will see a file a like this

<RelativeLayout xmlns:android=""
    tools:context=".Android_test" >

        android:id="@+id/lblTextViewOne" />

        android:text="CLICK ME" />

Relative Layout is the way of containing and organizing element inside of it.The Relative Layout is used to display a block of text.

STEP 3: Now go to src->com.Example.Android_1
and open the file once there.And write the code as given given:

package com.example.android_1;

import android.os.Bundle;
import android.content.Intent;
import android.view.Menu;
import android.view.MotionEvent;
import android.view.View;
import android.view.View.OnTouchListener;
import android.widget.Button;
import android.widget.EditText;
import android.widget.TextView;

public class Android_test extends Activity {

	protected void onCreate(Bundle savedInstanceState) {

		final TextView TextViewOne = (TextView) findViewById(;



Explantation of
Android_test class is extending the Activity class (which is part of Android SDK).We are only overriding one method from the Activity subclass,the “onCreate” method .This method is called when the activity is created and also when the screen is rotated.We call super.onCreate method so that the Activity subclass can handle its plumbing and then we call setContentView .This method is passed R.Layout.main .R is a way to refer to res folder and is how we pro-grammatically access the items in that folder.

All we need to do is to create a new string and then use your TextView to use that String in the onCreate method.
let’s add an string to string.xml

<stringname="test_one">This is my first App</string>

Screenshot from 2013-03-15 12:25:29
then go back to activity_android_test.xml/main.xml

and add an id to it like


again go to and write the following code

 TextView newtext=(TextView)findViewById(

if there is an error coming just import “TextView” or (android.widget)
again set the property of the Textview as


Now your app is ready is ready to run.Just clean and build and RUN AS ANDROID APPLICATION
You will see an updated text.


2 thoughts on “Android :Learn to make your own Android App

  1. This is very inspiring, as getting from the start & Having no real background in programming (aside from making some adventures on ZX-81 and MSX), this does sound like I could get started on developing something for my own Android based eBook reader and android app development training even this online course seems to be interesting Has anyone tried any online courses so far. Please do provide a light on this also.

    Thankyou for all the info also.

  2. This is very good publishing regarding Android Application development . Android application is an open source so everyone can learn it. It is very good & useful article for those who want to learn about android application development.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s