SharePoint firing Create event twice?

  • 9 February 2012
  • 1 reply
  • 4 views

Badge +2


Ok, situation recap.


 


Due to a bad design, I have had
to integrate a workflow with the Document content type, so that some custom
content types which obviously inherit from Document can be controlled.


The workflow is integrated for the Create event, not the Modify event.


When a new item is added to a
library, SharePoint obviously gives it the default content type for that
library.


A create event is fired for the
default content type.


The event is passed through to
K2, which starts a new process.


In SharePoint the Properties
dialog for the item is opened.


The user changes the content
type and saves it.


Another event is fired for the new
content type.


The event is passed through to
K2, which starts another new process.


 


The assumption here is that the
event SharePoint is firing the second time is a Create event, since K2 is only integrated with
the Create action.


 


Any idea why SharePoint is
firing Create twice?


Or is there an issue in K2 1230
where it is listening to the wrong event, and misinterpreting as a Create?



1 reply

Badge +2

Been a while, any idea guys?


I ended up switching over to using the Updated event instead. This resulted in far fewer occurences of the double event firing, but it is still happening.


I read about how when you perform a check-out it forces another ItemUpdate event to fire, however the two processes I am getting are both being started within milliseconds of each other. So the second is not being started by the first performing a check-out.


Also I added a mechanism using the SmartBox to ensure that if a second process was started by a check-out, it could check a flag set by the first process to test whether it should actually just end gracefully, which is working fine.


This is driving me nuts.


It's K2 Blackpearl 4.5 1230 and SharePoint 2010. Perhaps this combination is driving the problem?

Reply