1

I have Exchange on Office365 and a local Exchange 2010 both of which I use for EWS communication. When I issue request to the Exchange on Office365 I get back a response in a certain format, this format differs from the content I get back from the local Exchange 2010.

Specifically, I have pull notifications up and running. Every minute I issue a GetEvents request to get the events that were created/modified/deleted since the last notification. The issue is that when I modify an event in the calendar, I do get a notification of a modified event, but I get several of them and I also get a notification that an event has been created, but no, only one event was modified.

So why does EWS send back a response with multiple modified objects and a single created object.

This is only an issue when an event is modified, creating an item works fine.

Also are there any other specific issues I need to look out for when dealing with notifications?

eomeroff
  • 9,599
  • 30
  • 97
  • 138

1 Answers1

0

Sometimes I wish Exchange Documentation wasn't as bad.

The reason why you get many items in a single event is because the event also contains the parent folder of the item that was modified because most things in Exchange occur at the folder level. With that said you get 2 types of objects literally ItemEvent and FolderEvent. You can filter them using linq of some if statement ex.

    lstCreatedContactIds = From e In     pArgs.Events.OfType(Of ItemEvent)()
                           Where e.EventType = EventType.Created
                           Select e.ItemId
rojobo
  • 476
  • 4
  • 16