How to send an email from my application using email application?
Question
How to send an email from my application using email application?
I am having the one scenario like send email to particular mail id(info@jeltech.com
). In my application while clicking the link it should call email application and then need to pass above mail id to in "To" box (after login) .
Is there any solution for this issue?
Regards,
Jeyavel N
Solution
You can use the following code to launch the action ACTION_SENDTO
in a new activity
Intent intent = new Intent(Intent.ACTION_SENDTO,
Uri.fromParts("mailto", "test@test.com", null));
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
context.startActivity(intent);
OTHER TIPS
You could use the html syntax and embed a html link into your application.
I'm not 100% sure it will work with android but I don't see any reason why it wouldn't work.
Hope this helps Pete
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow