1. Email Task: You can call the system Email program to send emails.
Before sending the email, you need to set up an email account to send the email. However, the full version is not set. It seems that the email cannot be sent on the simulator, so you can save the settings. This Task can be used only on a real machine.
EmailComposeTask email = new EmailComposeTask ();
Email. Body = "test my email by wp7 emulator ";
Email. Subject = "test ";
Email. To = "aa@hotmail.com ";
Emai. Cc = bb@hotmail.com ";
Email. Show ();
2. Email Address chooser Task: used to open the contact program and select the contact Email address.
This Task can be selected only when the contact and email address are added. However, this program is not available in the official simulator, and you cannot add contacts through this program, therefore, if you want to use this Task without a real machine, you need a full simulator. At present, the foreign cool man has cracked the Beta version of the simulator and can get the full version. I mentioned a cracked version of the image file before, but it can only be viewed, and now the new full version can be debugged. The following is done through the full version of the simulator.
Contact created on the simulator:
Start and select contacts:
EmailAddressChooserTask chooser = new EmailAddressChooserTask ();
Chooser. Completed + = new EventHandler <EmailResult> (chooser_Completed );
Chooser. Show ();
Void chooser_Completed (object sender, EmailResult e)
{
E. Email // obtain the Email address of the selected contact here
}
3. Save Email Address Task: You can call the contact program and Save the set Email address to the selected contact or create a contact.
SaveEmailAddressTask SaveAddr = new SaveEmailAddressTask ();
SaveAddr. Email = "cc.hotmail.com ";
SaveAddr. Completed + = new EventHandler <TaskEventArgs> (SaveAddr_Completed );
SaveAddr. Show ();