Outlook发信
using System;
using Microsoft.Office.Interop.Outlook;
namespace ConsoleApplication1 {
internal class Program2 {
private static void Main() {
var app = new ApplicationClass();
var mailItemClass = app.CreateItem(OlItemType.olMailItem) as MailItem;
mailItemClass.To = "rickie.du@sap.com";
mailItemClass.Subject = "Send File As Email Attachment";
mailItemClass.Attachments.Add("c:\\a.txt", Type.Missing, Type.Missing, Type.Missing);
mailItemClass.Send();
Console.WriteLine("COOL");
}
}
}