Oxygene and WP8 – EmailComposeTask Launcher

Oxygene and Windows Phone 8 tutorials – Article Index

The EmailComposeTask launcher lets the user send email from your Windows Phone app. This launcher launches the Email Application and populates the Message subject, body and the “to” address as specified to the EmailComposeTask. When the user taps on the “Send” button in the Email Compose screen, the email is sent.

How to use the EmailComposeTask Launcher in Windows Phone 8 with Oxygene?

To use the EmailComposeTask launcher with Oxygene, follow the below steps.

1. Include the following namespace in the code behind file.

uses
Microsoft.Phone.Tasks;

2. Create an instance of the EmailComposeTask and set the To , Body and the Subject property of the EmailComposeTask object and then call the Show method . This will launch the Email Application prepopulated with the data provided .

var emailComposeTask: EmailComposeTask := new EmailComposeTask();
emailComposeTask.To := "[email protected]";
emailComposeTask.Body := "Welcome to the developerpublish Oxygene and WP8 tutorial series";
emailComposeTask.Subject := "developerpublishWelcome Message";
emailComposeTask.Show();

Oxygene and WP8 - EmailComposeTask Launcher

Test the EmailComposeTask on the Windows Phone device. If an email account is not configured in the phone, the app prompts the user to setup an email account.

Download the sample source code on EmailComposeTask Launcher in Oxygene and WP8 here

Leave A Reply

Your email address will not be published. Required fields are marked *

You May Also Like

This blog post will guide you through several effective methods to troubleshoot and resolve the issue of Microsoft Edge not...
Windows 11 offers a range of audio enhancements that can enrich your listening experience. These enhancements include features like virtual...
Windows 11 brings a fresh and visually stunning design to your desktop, and one of the standout features is the...