All I want to do is show the user the email that has been created and allow them to modify / choose when to send.
Thanks very much in advance.
Will.
using
/// This Code is adopted from Microsoft Knowlegdebase Article: <http://support.microsoft.com/?kbid=220600>
// The Outlook Application Object
Outlook.ApplicationClass myOutlookApplication = null;
// Create the Application Object
myOutlookApplication = new Outlook.ApplicationClass ();
// Get the Namespace Object
Outlook.NameSpace myNameSpace = myOutlookApplication.GetNamespace("MAPI");
// Define a missing Object for COM interop
object myMissing = System.Reflection.Missing.Value ;
// Logon to Namespace
myNameSpace.Logon(myMissing, myMissing, myMissing, myMissing);
// Create a Mail Object
Outlook._MailItem myNewMail = (Outlook._MailItem)myOutlookApplication.CreateItem(Outlook.OlItemType.olMailItem);
//Outlook.MailItemClass myNewMail = (Outlook.MailItemClass) myOutlookApplication.CreateItem (Outlook.OlItemType.olMailItem);
myNewMail.To = "[email protected]";
myNewMail.Subject = "About our meeting...";
myNewMail.Body = "Hi James,\n\n" +
"\tI'll see you in two minutes for our meeting!\n\n" +
"Btw: I've added you to my contact list!";
// Send the message!
myNewMail.Send();
//* CleanUp
Marshal.ReleaseComObject (myNewMail);
myNameSpace.Logoff ();
Marshal.ReleaseComObject (myNameSpace);
Marshal.ReleaseComObject (myOutlookApplication);