我需要通过调用BPOS中的Exchange Web服务来检索日历信息。我正在使用一个
当获取整个约会时,我可以通过
CalendarView
和一个PropertySet
来尽可能少地检索数据。然而,属性集似乎是有限制的。我需要制定日历约会的人的EmailAddress
,所以我想我可以在PropertySet
中使用AppointmentSchema.Organizer
。当获取整个约会时,我可以通过
appt.Organizer.EmailAddress
获得电子邮件。但是,在下面的代码中,Organizer.EmailAddress
始终为空。我已经启用了跟踪并进行了检查,只发送了Organizer.Name
属性,没有其他信息。是否有人知道如何在使用PropertySet
时获取EmailAddress
的解决方案?CalendarView view = new CalendarView(dtFrom, dtTo);
view.PropertySet = new PropertySet(ItemSchema.Subject);
view.PropertySet.Add(ItemSchema.Id);
view.PropertySet.Add(AppointmentSchema.Start);
view.PropertySet.Add(AppointmentSchema.End);
view.PropertySet.Add(AppointmentSchema.Organizer); // This should contain EmailAddress but it doesn't
Mailbox mailbox = new Mailbox("myemail@test.ab");
FolderId id = new FolderId(WellKnownFolderName.Calendar, mailbox);
CalendarFolder folder = CalendarFolder.Bind(service, id);
FindItemsResults<Appointment> findResults = folder.FindAppointments(view);