フォーム領域を IPM.Appointment メッセージ クラスに追加する Outlook アドインに取り組んでいます。この領域が表示されると、最初にいくつかのプロパティが AppointmentItem に追加されます。
Outlook.AppointmentItem appItem;
private void FormRegion_FormRegionShowing(object sender, System.EventArgs e)
{
try
{
appItem = (Outlook.AppointmentItem)this.OutlookItem;
appItem.ItemProperties.Add("CustomProperty", Outlook.OlUserPropertyType.olText);
}
catch (Exception ex)
{
MessageBox.Show(ex.ToString());
}
}
これは自分のカレンダーでは正常に機能しますが、編集者または所有者のアクセス権を持つ代理カレンダーでアドインを使用しようとすると、次の例外がスローされます。
System.UnauthorizedAccessException: You don't have appropriate permission to perform this operation.
at Microsoft.Office.Interop.Outlook.Itemproperties.Add(String Name, OlUserPropertType Type, ObjectAddToFolderFields, Object DisplayFormat)
at ThisAddin.FormRegion.FormRegion_FormRegionShowing(Ovject sender,EventArgs e)
どんな助けでも大歓迎です!