I'm working on building a synchronizer for certain kinds of data from some lists to an outside application. Via the SOAP API, I can get updates and new items; by using CAML Queries, we can fetch all items modified/created within particular time ranges as well.

How do we detect via the SOAP API when deletes take place? Presumably, if a document is deleted from a library or a list item removed, it goes to the recycle bin, but doesn't show as modified in that list or library. In order to have a synchronizer though, we need to be notified of that delete event.


Use the change log.

I describe using the change log from CSOM in this article: http://www.schaeflein.net/reading-the-sharepoint-change-log-from-csom/

| improve this answer | |

There is no option to retrieve deleted items (You can use Event Receiver and handle ItemDeleted Event, then some how notify the Synchronizer).

The best workaround I can think of is to get the count of items.

  1. Find all new items and sync it
  2. Find modified items and sync it
  3. Get the item count from SharePoint - Compare it with the item count in Synchronizer. If count doesn't match, then an item is deleted. Now you need to iterate and find which item is deleted.
| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.