I have written a code in which I am allowing user to send order via email to vendor [ShopOwner] along with their personal and cart item details, but here I am getti
Rakesh sorry for late reply, since 10 am i was trying to resolve your issue and i have tried several times and finally below code has worked:
i knew you got answer, but i have given many hours for my satisfaction i am placing my answer here, and brother i don't need points for this, because @SahilMahajanMj deserve this:
Intent i = new Intent(Intent.ACTION_SEND);
i.putExtra(Intent.EXTRA_EMAIL , new String[]{"rakesh@rocketmail.com"});
i.putExtra(Intent.EXTRA_SUBJECT, subject);
i.setType("message/rfc822");
i.putExtra(Intent.EXTRA_TEXT, Html.fromHtml(body.toString()));
try {
startActivity(Intent.createChooser(i, "Send email via :"));
} catch (android.content.ActivityNotFoundException ex) {
Toast.makeText(ArrowsActivity.this, "There are no email applications installed.", Toast.LENGTH_SHORT).show();
}