Hi all,
I am new in android.I need one help from all.
I need to send the email, I have tryed in emulator, i have checked
my mail but i didnt got any mail,. how to do that?? Plz give me a
solution for that.
I have mention below the my code for your reference.
package com.test.android;
import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;
public class auboutus extends Activity {
/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.aboutus);
Button aboutUs_button = (Button)
findViewById(R.id.aboutUs_button);
aboutUs_button.setOnClickListener(new OnClickListener() {
public void onClick(View arg0) {
Intent i = new Intent(Intent.ACTION_SEND);
i.setType("text/plain");
i.putExtra(Intent.EXTRA_EMAIL, new String[]
{"[email protected]"});
i.putExtra(Intent.EXTRA_SUBJECT,"subject goes here");
i.putExtra(Intent.EXTRA_TEXT,"body goes here");
startActivity(Intent.createChooser(i, "Select email
application."));
}
});
}
}
Thanks
C.RAjesh
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en