Total Pageviews

Search This Blog

Friday, December 31, 2010

Contd..How to Add multiple Search Criteria using EWS

This is in continuation with the previous posts on integrating Dynamics AX with Exchange Web Services without installing Outlook on your box. If you missed the previous posts, you can browse them from here:

Had this requirement to add multiple search criterias for filtering emails based on different subjects. For this, I had to use the SearchFilterCollection method to achieve it, below is the code snippet on how to achieve it. The code is pretty self explanatory as the SearchFilterCollection object can handle logical operators like Or, And etc. and you can pass multiple SearchFilters to it as shown here.

If you want to delve more indepth, you can read the MSDN article below:

No comments: