View RSS Feed

Recent Blogs Posts

  1. Launching Android Applications on a Device

    by , 02-11-2012 at 12:44 PM
    To load Android application on your device, plug your Android device using USD data cable to your computer. Also check you debugging setting to confirm that you have configured this device for debugging. Follow these steps to make sure that you are using correct settings for debugging.

    • From Java perspective, select Run -> Debug configurations.
    • Double click your configurations.
    • Change your “Deployment Target Selection Mode” to manual on Target tab. You can get ...
  2. Simulating Incoming Calls to the Emulator

    by , 02-11-2012 at 12:40 PM
    Using DDMS Emulator control tab, incoming voice calls can be simulated. It is not a real call and no voice or other data is transmitted between the 2 parties. It is just a simulation of incoming calls as shown in below figure.

    Name:  1.JPG
Views: 886
Size:  25.1 KB
    Simulating Incoming Calls to the Emulator

    Follow below steps to simulate incoming call on your emulator that is running on your server.
    • Select emulator instance to call in the DDMS perspective. ...
  3. Android Project Files in Eclipse

    by , 02-11-2012 at 12:29 PM
    In this section we will explain different files automatically created with a new android project in eclipse.

    • AndroidManifest.xml: Main configuration’s file for the application.
    • default.properties: Build file used by Eclipse and Android ADT plug-in.
    • proguard.cfg: Build file used by Eclipse, ProGuard, and the Android ADT plug-in. You can edit and configure this file to optimize your code.
    • src folder: This folder contains all the source code.
    • Activity.java: ...
  4. Creating Hello World Android Project in Eclipse

    by , 02-11-2012 at 12:28 PM
    In this section, we will create a simple Hello World Android Project in Eclipse. Launch you Eclipse and follow these steps to create a simple project.

    • Click File -> New -> Android Project.
    • Enter a project name. For example “Droid1”.
    • Select a folder for the project source.
    • Next you need to select build target for your Android Project. Select most suitable for your target audience and application. For example if you want to use Google Maps, then ...
  5. Performing Fragment Transactions

    by , 02-11-2012 at 12:25 PM
    You can add, remove, replace or perform actions with fragments in your activity in response to user interaction. A transaction is a set of changes you perform to an activity and these can be performed using APIs in FragmentTransaction. These transaction can be saved on back stack and allow the user to navigate these changes.

    To get an instance from FragmentManager, following code is used.


    Java Code: This is the code to create a fragment
    FragmentManager fragmentManager = getFragmentManager()
    ...
  6. Building and Running Android Application from Eclipse with ADT

    by , 02-11-2012 at 11:09 AM
    Details of the build process are hidden when using Eclipse and ADT. Build process in running continuously in background and automatically build application when you make changes to code. Following topics will explain how to run application.

    Running on the emulator

    Create an AVD when you are running your application on the Android Emulator. Follow these steps to run your application

    • From Eclipse menu bar select Run > Run (or Run > Debug) from the ...
  7. Building and Running an Android Application

    by , 02-11-2012 at 11:04 AM
    An Android project is compiled and packaged into “.apk” file. It is the container for application binary. It contains following information that is necessary to run your application on a device or emulator

    • Compiled “.dex” files
    • Binary version of Manifest file
    • Compiled resources
    • Uncompiled resource files for your application

    If Eclipse is being used as development IDE, the ADT plug-in is responsible for building your project when source ...

    Updated 02-11-2012 at 11:06 AM by Android Development

    Categories
    Build Application , Run Application
  8. Android Manifest File

    by , 02-11-2012 at 11:00 AM
    Whenever an Android Application is loaded, the application's AndroidManifest.xml file also called “manifest file” is read by the Android system. All the components are declared in this file by the Android application. Also it is placed at the root of application project directory.

    Following are the major tasks that are performed by the manifest other than just declaring the application’s components.

    • User permissions such as Internet access or read access to user’s
    ...
  9. Android Application Framework

    by , 02-11-2012 at 10:58 AM
    Android Application Framework supports development of rich and innovative mobile applications. Android Application Framework is open source and uses Java Programming language. Android developers can take benefits of the hardware device, access location information, background services, alarms, ability to add notifications and many other benefits.

    Core applications uses framework APIs and developer complete rights to those APIs. The architecture of application is based on reusability ...
  10. Referencing Application Resources

    by , 02-11-2012 at 10:53 AM
    All the application resources are compiled at build time and are stored in “res” project directory structure. These resources can also be used programmatically. Also they can refer to other resources in application. These application resources are accessed using class file R.java programmatically. Get the application’s resource object and call getResource() method to reference a resource in your activity class. After this call the appropriate method to access your desired resource.

    ...
    Categories
    Android Resource
  11. How to access Android Application Preferences?

    by , 02-11-2012 at 10:51 AM
    You can use getSharedPreferences() method of your application context to get your application preferences. Also SharedPreferences class support saving of application data like configuration settings. You need to assign each SharedPreferences object a different and unique name that enables you to arrange preference values in different categories and can store all preferences in on large unnamed set.

    For example, if you are interested in storing user name and game statistics like how ...
  12. Android Application Context

    by , 02-11-2012 at 10:43 AM
    For all the core application functionality, application context is central location. It is used to access resources that are shared between activity instances and is used to access settings. Use getApplicationContext() method to get the application context for current process.

    Java Code:
    Context context =  getApplicationContext()
    You can also use this object when writing code in your Activity class because Activity class is derived from the Context class. After ...
  13. Managing Android Virtual Devices

    by , 02-11-2012 at 10:40 AM
    Android Virtual Device (AVD) is configured in order to execute an application in the Android Emulator. In AVD profile, the type of device is described that you want to simulate in the emulator and it also includes Android platform to support. Different screen sizes and resolution are specified and also can specify an SD card. Follow these steps to create a basic AVD:

    1. In Eclipse launch Android SDK and AVD Manager by clicking the Android icon in meny bar. Also you can select it from ...
  14. Edit a String Resource

    by , 02-11-2012 at 10:38 AM
    Open an Eclipse Android project and examine main.xml file. You will find that it has a TextView control layout. This TextView control interface simply displays a string. The string displayed in this case is defined in string resource called “@string/hello”.

    If you want to edit this string resource using string resource editor, follow these steps:

    • Double click strings.xml file in package explorer of Eclipse and it will open in the resource editor.
    • Select String
    ...
  15. Edit Android Manifest File

    by , 02-11-2012 at 10:09 AM
    Manifest information is managed in different tabs by file editor. These tabs are as follow:

    • Manifest: This tab is used for application general settings such as version information, package name etc.
    • Application: Application details such as name, icon and “guts” are defined under this tab. Like what application can run and what other services application can provide.
    • Permissions: Application’s permissions are defined under this tab. If application wants to read a contact from
    ...
  16. Android Activity Lifecycle

    by , 02-11-2012 at 10:00 AM
    All fundamental lifecycle methods of an activity are given in below code skeleton.

    Java Code: This is the code to manage lifecycle of an activity
    public class ExampleActivity extends Activity {
        @Override
        public void onCreate(Bundle savedInstanceState) {
            super.onCreate(savedInstanceState);
            // The activity is being created.
        }
        @Override
        protected void onStart() {
            super.onStart();
            // The activity is about to become visible.
    ...
  17. Android Activities

    by , 02-11-2012 at 09:44 AM
    A single screen in Android application is provided by an activity. You can move these Activities into background and then resume.

    It is just like a screen where a user interacts and performs some actions such as dial the phone, view map, send email, take a phone etc. User interface is drawn into an Activity window. Screen is usually filled by the window or it may float on top of different other windows.

    Different bounded or integrated activities create an application. ...
    Categories
    Android Activity
  18. Android Introduction

    by , 02-11-2012 at 09:40 AM
    Android includes following at its core:

    1. Key Applications
    2. OS
    3. Middleware

    Android SDK consists of different APIs & tools to start developing mobile applications on Android platform. The programming language is Java that is being used for development of these applications.

    Core Features

    1. Application framework: It is used to replace and reuse different components
    2. Dalvik VM (Virtual Machine): An optimized ...
    Tags: android, tutorial Add / Edit Tags
    Categories
    Tutorial