Sometimes an app need to send some information via email. To reach this gol a programmer need to write a few lines of code.
First of all, we can create a button and attach the Click event to send email. After that, in this event we call the EmailComposeTask and thats all.
Now we can build our email with the usual parameters (To, Subject, Body) and then we send the email.
EmailComposeTask email = new EmailComposeTask(); if ("<email_address>" != string.Empty) { email.To = "<email_address>"; email.Subject = "Subject message"; email.Body = "Body message"; email.Show(); } else { MessageBox.Show("Some error occours.", "WARNING", MessageBoxButton.OK); }