Category Archives: Android Tutorial

Communication Between Activity and Fragment Example

android-logoAfter received many requests from online users of my Android blog, I have posted the complete tutorial about the communication between activity and fragment Example. Here you can learn how a simple fragment can communicates with an Activity in Android. We will use simple  getFragmentManager() API  and Fragment Class in Android to complete this task .

Insert New Contact in Android Code Example

android-logoInsert new contact in Android is very easy. Here we will learn how to add a new mobile number  into Android Contacts list programmatically. We will use inbuilt Android classes (ContactsContract, ContentProviderOperation) to add new contacts in Android Contacts List. Below is the code snippet with example and detailed description.

Read Multiple Phone Numbers From Android Contacts List Programmatically

android-logo It is very easy to retrieve phone numbers in Android. This is how you can read multiple phone numbers from Android Contacts List programmatically. If a contact has multiple phone numbers, then You can retrieve all phone numbers and other details using Android’s inbuilt classes (Cursor and ContactsContract ) in Android. 

Get Running Applications List in Android Example

get-installed-application-list-androidHere we will discuss about how to get running applications list in Android with an simple example. There are many applications and services which are running in your Android device. We can use  ActivityManager.getRunningTasks(Integer.MAX_VALUE) API to get list of all running tasks in Android.

Get Installed Applications List in Android Example

get-installed-application-list-androidHere you will find the simplest way to get installed applications list in Android Phones. We can retrieve all installed applications list using PackageManager and ResolveInfo in Android. ResolveInfo and PackageManager are Android components which provides us all installed applications details as per our requirement.

Send Email From an Android Application programmatically


Here we will discuss about how to send Email from an Android application programmatically. Simple we will use Intent.ACTION_SEND action with an existing email client like (gmail or something else) to send the email. Here in our example we will take inputs from user ( like To, Subject, Message) and will send it by invoking any of the existing email client, which is already installed in your device.