Domanda

I have a question about SharePoint 2010 and the technical differentiation between an item move and a deletion in an event receiver. As I could see, when moving a document to another library, the ItemDeleting and ItemDeleted events are also called. So how do I differentiate in the event receiver whether a document is really deleted or just moved to another library?

Has anyone here already gained experience?

È stato utile?

Soluzione

I've got the answer. In the SPItemEventProperties in the event receiver is the property AfterUrl. On deletion this property is null, on movement it contains the new url of the item.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a sharepoint.stackexchange
scroll top