如何调用调用系统邮件程序包括Gamil

用G1上某些程序点击某功能后会弹出让用户选择"E-MAIL"OR "GMAIL"的选项,其方法如下如下:
//建立Intent 对象
final Intent emailIntent = new Intent(android.content.Intent.ACTION_SEND);
//设置文本格式
emailIntent.setType("plain/text");

//设置对方邮件地址
emailIntent.putExtra(android.content.Intent.EXTRA_EMAIL, new String[]{[email={××××××@gmail.com]××××××@gmail.com[/email]});

//设置标题内容
emailIntent.putExtra(android.content.Intent.EXTRA_SUBJECT, "Hello World!");

//设置邮件文本内容
emailIntent.putExtra(android.content.Intent.EXTRA_TEXT, "It is body-Hello World!");

//启动一个新的ACTIVITY,"Sending mail..."是在启动这个ACTIVITY的等待时间时所显示的文字
startActivity(Intent.createChooser(emailIntent, "Sending mail..."));

你可能感兴趣的:(邮件)