Snippets

Set the application icon

To set the application icon in Android you have to open the project’s Manifest.xml file and add the following attribute to the application tag: <application android:icon=”drawable resource”> Before you do that make sure you add the icon image in one of your drawable directories.. If you called your icon: app_icon.png then the application tag should look

, ,
Solutions, Tutorial

Android Broadcast Receiver Example with Parcelable

In this tutorial I will show you how to use Broadcast Receiver and how to use Parcelable too. To do this, we will create an ExpandableList which will have parents and children(they will contain only their names). The children will be an arrayList of strings and because we want to pass this array with an

, , , ,
Tutorial

Android Expandable List Example

In this tutorial I will show you how to make a simple Expandable List. 1. Create a new project and call your java class(the one that is generated by Eclipse or other IDE) “MyActivity”. 2. Go to res – layout -main.xml and put the following code: <?xml version=”1.0″ encoding=”utf-8″?> <LinearLayout xmlns:android=”http://schemas.android.com/apk/res/android” android:orientation=”vertical” android:layout_width=”fill_parent” android:layout_height=”fill_parent” >

, , , ,
Snippets, Solutions

Add image to email intent in Android

How to add image to an email intent in Android: // build a email sending intent Intent emailIntent = new Intent(android.content.Intent.ACTION_SEND); emailIntent.setType(“image/png”); // set the email subject emailIntent.putExtra(Intent.EXTRA_SUBJECT, “email subject”); // set the email image path for the attachment emailIntent.putExtra(Intent.EXTRA_STREAM, Uri.parse(“file://” + mEmailImagePath)); // set the body of the email emailIntent.putExtra(Intent.EXTRA_TEXT, “some text message”);

, , , ,
Info

My Applications

Here I will post the applications developed by us. 1. Number Series  Number Series is a logical game with numbers, just perfect for you if you like to challenge your brain. You have to go through 10 levels with varying degree of difficulty and you have only 3 lives to complete the game. What do

, ,
Tutorial

Android LayoutInflater Turorial

In this tutorial I will show you how to use the LayoutInflater in Android.1. Make a new project (I called my project InflaterExample and my main Activity it’s called “MyActivity”) 2. Go to res – layout – main.xml and put an id called “main_layout_id” <LinearLayout xmlns:android=”http://schemas.android.com/apk/res/android” android:orientation=”vertical” android:layout_width=”fill_parent” android:layout_height=”fill_parent” android:id=”@+id/main_layout_id”> </LinearLayout> 3. Go to res

,
sponsored
Exit mobile version