The project describes how to port an application in more than one language.

Underlying Algorithm:
Basic description of algorithm in step by step form:

1.) Create a Project LocalizationExample

2.) Open and insert following in main.xml:


android:layout_height="fill_parent" xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_height="wrap_content" android:background="@drawable/background"
android:id="@+id/countryimage" android:layout_above="@+id/infotext">
android:layout_height="wrap_content" android:text="@string/info_text"
android:layout_alignParentBottom="true" android:textColor="@color/White"
android:textSize="24dip" android:layout_centerHorizontal="true"



3.) Create and insert strings for various languages in Values/strings.xml. The structure should be shown as below:

4.) Run the application.

Steps to Create:

1.) Open Eclipse. Use the New Project Wizard and select Android Project Give the respective project name i.e. LocalizationExample. Enter following information:

Project name: LocalizationExample
Build Target: Android 2.3.3
Application name: LocalizationExample
Package name: org.example.LocalizationExample
Create Activity: LocalizationExample

On Clicking Finish LocalizationExample code structure is generated with the necessary Android Packages being imported along with LocalizationExample.java. LocalizationExample class will look like following:


package org.examples.LocalizationExample;

import android.app.Activity;
import android.os.Bundle;

public class Localization extends Activity {
/** Called when the activity is first created. */
public void onCreate(Bundle savedInstanceState) {



Output –The final output:


If you browse JOME -> Menu -> Settings -> Languages -> Select language and change the handset’s default language as follows:

Then on re-launching the localization app it will give you some different output in the language you selected as default.


Leave a Comment:

1 comment
Alex B says February 21, 2013

I recommend this localization software for better results in localizing apps: https://poeditor.com/

Add Your Reply