Фильтрация встреч с сервера Exchange

IEWSClient предоставляет возможность фильтровать встречи с сервера Exchange с использованием ExchangeQueryBuilder. Встречи могут быть отфильтрованы по:

  • Датам
  • Повторениям

Фильтрация встреч по датам

// For complete examples and data files, please go to https://github.com/aspose-email/Aspose.Email-for-C
System::SharedPtr<IEWSClient> client = GetExchangeEWSClient(GetExchangeTestUser());
System::DateTime startTime(2017, 9, 15);
System::DateTime endTime(2017, 10, 10);
System::SharedPtr<ExchangeQueryBuilder> builder = System::MakeObject<ExchangeQueryBuilder>();
builder->get_Appointment()->get_Start()->Since(startTime);
builder->get_Appointment()->get_End()->BeforeOrEqual(endTime);
System::SharedPtr<MailQuery> query = builder->GetQuery();
System::ArrayPtr<System::SharedPtr<Appointment>> appointments = client->ListAppointments(query);

Фильтрация встреч по повторяющимся событиям

// For complete examples and data files, please go to https://github.com/aspose-email/Aspose.Email-for-C
builder = System::MakeObject<ExchangeQueryBuilder>();
builder->get_Appointment()->get_IsRecurring()->Equals(false);
query = builder->GetQuery();
appointments = client->ListAppointments(query);