<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2900.2627" name=GENERATOR></HEAD>
<BODY>
<DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN 
class=791224809-02062005>It's a bit late I guess, but I would recommend using a 
check function instead. Then you prevent starting the second instance by looking 
for existing workflows related to your purchase order (function 
SAP_WAPI_WORKITEMS_TO_OBJECT). </SPAN></FONT></DIV>
<DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN 
class=791224809-02062005></SPAN></FONT>&nbsp;</DIV>
<DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN 
class=791224809-02062005>The fewer workflows started, the better - unless your 
salary depends on the number of started workflows.</SPAN></FONT></DIV>
<DIV align=left><FONT face=Arial size=2>-- </FONT></DIV>
<DIV align=left><FONT face=Arial size=2>Kjetil Kilhavn, Statoil KTJ IT 
BKS</FONT></DIV>
<DIV><FONT face=Arial color=#0000ff size=2></FONT>&nbsp;</DIV><FONT face=Arial 
size=2></FONT><FONT face=Arial size=2></FONT><BR>
<DIV class=OutlookMessageHeader lang=en-us dir=ltr align=left>
<HR tabIndex=-1>
<FONT face=Tahoma size=2><B>From:</B> sap-wug-bounces@mit.edu 
[mailto:sap-wug-bounces@mit.edu] <B>On Behalf Of </B>Amit Moghe<BR><B>Sent:</B> 
2. juni 2005 10:32<BR><B>To:</B> sap-wug@mit.edu<BR><B>Subject:</B> AW: 
Cancelling the previous workitem<BR></FONT><BR></DIV>
<DIV></DIV>
<P>Hi Michael,<BR><BR>&nbsp; Thanks a lot for the help. It works 
perfectly...&nbsp; <BR><BR>Regards,<BR>Amit<BR><BR>--------<BR>&nbsp; Hi 
Amit,<BR><BR>&nbsp; You can built a parallel processing in Your workflow, which 
ends,&nbsp; <BR>&nbsp; if one of the both branches is completed. One branch 
includes Your <BR>&nbsp; current workflow and the other consits of a Wait Step , 
which waits <BR>&nbsp; for the event 'CHANGED' of BUS2012.<BR><BR><BR>&nbsp; 
Best regards<BR>&nbsp; Michael Ludwig<BR>&nbsp; rku.it GmbH<BR><BR>&nbsp; &nbsp; 
&nbsp;-----Ursprüngliche Nachricht-----<BR>&nbsp; &nbsp; &nbsp;Von: 
sap-wug-bounces at mit.edu [mailto:sap-wug-bounces at mit.edu] Im Auftrag von 
Amit Moghe<BR>&nbsp; &nbsp; &nbsp;Gesendet: Donnerstag, 2. Juni 2005 
08:34<BR>&nbsp; &nbsp; &nbsp;An: sap-wug at mit.edu<BR>&nbsp; &nbsp; &nbsp;Cc: 
amitpmoghe at rediffmail.com<BR>&nbsp; &nbsp; &nbsp;Betreff: Cancelling the 
previous workitem<BR>&nbsp; &nbsp; &nbsp;<BR>&nbsp; &nbsp; &nbsp;<BR><BR>&nbsp; 
&nbsp; &nbsp;Hi Workflow Gurus,<BR>&nbsp; &nbsp; &nbsp;<BR>&nbsp; &nbsp; &nbsp;I 
am new to workflow and need some help.<BR>&nbsp; &nbsp; &nbsp;<BR>&nbsp; &nbsp; 
&nbsp;I have a workflow for which I am using 'CHANGED' event of the business 
object BUS2012 (Purchase Order) as the triggering event. When a user changes a 
particular PO, this workflow starts. But before it is completed if there is 
another change to the same PO, then, one more workitem is started.<BR>&nbsp; 
&nbsp; &nbsp;<BR>&nbsp; &nbsp; &nbsp;My requirement is that if there is change 
to the PO, then, it should delete the previous workitem and start a new 
workitem. Can you please advise me as to how this can be achieved?<BR>&nbsp; 
&nbsp; &nbsp;<BR>&nbsp; &nbsp; &nbsp;Thanks in advance.<BR>&nbsp; &nbsp; 
&nbsp;<BR>&nbsp; &nbsp; &nbsp;Regards,<BR>&nbsp; &nbsp; 
&nbsp;Amit<BR></P><p></p><p><font size=1>-------------------------------------------------------------------<br>The information contained in this message may be CONFIDENTIAL and is<br>intended for the addressee only. Any unauthorised use, dissemination of the<br>information or copying of this message is prohibited. If you are not the<br>addressee, please notify the sender immediately by return e-mail and delete<br>this message.<br>Thank you.</font size></BODY></HTML>