Note that there are some explanatory texts on larger screens.

plurals
  1. POItemUpdating called twice after ItemAdded in event receiver
    primarykey
    data
    text
    <p>I've created an event receiver to handle the ItemAdded and ItemUpdating events on a document library in SharePoint 2010.</p> <p>I've encountered a problem where when I add a document to the library (e.g. by saving it back from Word) the ItemAdded method is correctly called however this is then followed by two calls to ItemUpdating. I have removed all code from my handlers to ensure that it's not something I'm doing inside that is causing the problem. They literally look like:</p> <pre><code>public override void ItemUpdating(SPItemEventProperties properties) { } public override void ItemAdded(SPItemEventProperties properties) { } </code></pre> <p>Does anyone have a solution to this issue?</p> <p>Here is my elements.xml file for the event receiver:</p> <pre><code>&lt;Elements xmlns="http://schemas.microsoft.com/sharepoint/"&gt; &lt;Receivers ListTemplateId="101"&gt; &lt;Receiver&gt; &lt;Name&gt;DocumentsEventReceiverItemUpdating&lt;/Name&gt; &lt;Type&gt;ItemUpdating&lt;/Type&gt; &lt;Assembly&gt;$SharePoint.Project.AssemblyFullName$&lt;/Assembly&gt; &lt;Class&gt;My.Namespace.DocumentsEventReceiver&lt;/Class&gt; &lt;SequenceNumber&gt;10000&lt;/SequenceNumber&gt; &lt;Synchronization&gt;Synchronous&lt;/Synchronization&gt; &lt;/Receiver&gt; &lt;Receiver&gt; &lt;Name&gt;DocumentsEventReceiverItemAdded&lt;/Name&gt; &lt;Type&gt;ItemAdded&lt;/Type&gt; &lt;Assembly&gt;$SharePoint.Project.AssemblyFullName$&lt;/Assembly&gt; &lt;Class&gt;My.Namespace.DocumentsEventReceiver&lt;/Class&gt; &lt;SequenceNumber&gt;10000&lt;/SequenceNumber&gt; &lt;Synchronization&gt;Synchronous&lt;/Synchronization&gt; &lt;/Receiver&gt; &lt;/Receivers&gt; &lt;/Elements&gt; </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload