Outlook 経由で受信した電子メールを基本的に Web サイトにリンクできるようにする Outlook プラグインを作成し、Web サイトの通信機能でも電子メールを表示できるようにしました。MailItem の ItemProperties 内に追加の詳細を保存します。これらの詳細は基本的に、Web サイト内で電子メールが関連するユーザーの ID のようなものです。
私が抱えている問題は、メールの印刷時に MailItem に追加した ItemProperties が印刷されていることです。メールを印刷するときにカスタム ItemProperties を除外する方法を知っている人はいますか?
カスタム ItemProperty を作成するコードは次のとおりです。
// Try and access the required property.
Microsoft.Office.Interop.Outlook.ItemProperty property = mailItem.ItemProperties[name];
// Required property doesnt exist so we'll create it on the fly.
if (property == null) property = mailItem.ItemProperties.Add(name, Microsoft.Office.Interop.Outlook.OlUserPropertyType.olText);
// Set the value.
property.Value = value;