【发布时间】:2018-03-02 06:41:41
【问题描述】:
我们从 Outlook 创建会议,并将会议设置为私人会议。但是当使用 Exchange 服务器 API(EWS 托管 API)时,我们无法检索该信息,会议始终设置为“正常”,而不是“私人”。 Exchange Server 是否有任何设置阻止读取会议的敏感性属性?或者API是否有任何要求来获得该设置? 下面是示例代码:
DateTime startDate = DateTime.Now.AddDays(-1);
DateTime endDate = DateTime.Now.AddDays(1);
const int NUM_APPTS = 15;
// Initialize the calendar folder object with only the folder ID.
FolderId CalendarFolderIdVal = new FolderId(WellKnownFolderName.Calendar, "TrainingRoom@fmdemo.com");
CalendarFolder calendar = CalendarFolder.Bind(service, CalendarFolderIdVal, new PropertySet());
// Set the start and end time and number of appointments to retrieve.
CalendarView cView = new CalendarView(startDate, endDate, NUM_APPTS);
// Limit the properties returned to the appointment's subject, start time, and end time.
cView.PropertySet = new PropertySet(AppointmentSchema.Subject, AppointmentSchema.Start, AppointmentSchema.End,AppointmentSchema.Sensitivity);
// Retrieve a collection of appointments by using the calendar view.
FindItemsResults<Appointment> appointments = calendar.FindAppointments(cView);
在循环约会时,即使会议在 Outlook 中是私密的,也始终显示为“正常”。
【问题讨论】: