Messenger Activity In Android

This example is a simple messenger activity.


1.) Create a new project by File-> New -> Android Project name it MessengerActivity.

2.) Write following into main.xml:




3.) Write following into values/strings.xml:




4.) Run for output.


1.) Create a project named MessangerActivity and set the information as stated in the image.

Build Target: Android 4.0
Application Name: MessangerActivity
Package Name: com. example. MessangerActivity
Activity Name: MessangerActivity
Min SDK Version: 2.3

2.) Open file and write following code there:

package com.example.messangeractivity;




3.) Compile and build the project.


Leave a Comment:

Amy says March 18, 2013

R.layout.main/mainLayout and message_field cannot be resolved.

Taylor Bivin says November 13, 2013

I have recently started a web site, and the information you provide on this web site has helped me tremendously. Thanks for all of your time & work.

Add Your Reply