メールのインポート

VSTO

以下は、VSTO Outlook を使用してメールをインポートするコードです。


  string FilePath = @"E:\Aspose\Aspose VS VSTO\Sample Files\ImportEmail.msg";

 Outlook.MailItem email = (Outlook.MailItem)Application.Session.OpenSharedItem(FilePath);       

Aspose.Email

以下は、aspose.email for .NET を使用してメールをインポートするコードです。


  string FilePath = @"E:\Aspose\Aspose VS VSTO\Sample Files\ImportEmail.msg";  

 // loading with default options

  load from msg

   MailMessage eml = MailMessage.Load(FilePath, new MsgLoadOptions());

ソースコードのダウンロード

実行例のダウンロード