<br><font size=2 face="sans-serif">Maybe you could use:</font>
<br><font size=2 face="sans-serif">SAP_WAPI_WORKITEMS_TO_OBJECT with the various selection status variants:</font>
<br>
<br><font size=2 face="sans-serif">'0000' : all instances</font>
<br><font size=2 face="sans-serif">'0001' : active instances</font>
<br><font size=2 face="sans-serif">'0002': finished instances</font>
<br><font size=2 face="sans-serif">'0003': active instances (all)</font>
<br>
<br><font size=2 face="sans-serif">You have an indicator to specify if you only want top level (WS) items or everything. (incl. TS)</font>
<br>
<br><font size=2 face="sans-serif">Kind regards</font>
<br>
<br><font size=2 face="sans-serif">Koenraad</font>
<br>
<br>
<br>
<br>
<table width=100%>
<tr valign=top>
<td>
<td><font size=1 face="sans-serif"><b>Lyal.Schumann@rmc.co.uk</b></font>
<br><font size=1 face="sans-serif">Sent by: sap-wug-bounces@mit.edu</font>
<p><font size=1 face="sans-serif">16/12/2004 11:14</font>
<br><font size=1 face="sans-serif">Please respond to sap-wug</font>
<br>
<td><font size=1 face="Arial"> </font>
<br><font size=1 face="sans-serif"> To: sap-wug@mit.edu</font>
<br><font size=1 face="sans-serif"> cc: </font>
<br><font size=1 face="sans-serif"> Subject: Finding Workitems for a Document</font></table>
<br>
<br>
<br><font size=2 face="Arial">Howzit WF'ers</font>
<br><font size=3 face="Times New Roman"> </font>
<br><font size=2 face="Arial">I need to get the workitems attached to a specific document. In the past, I have have merrily used function module SWI_WORKITEMS_OF_OBJECT_GET to get these. However, on testing this, it seems that it doesn't return the workitems of any sub-workflows that happen to be raised in the process. I know I could then use something like SWI_GET_DEPENDENT_WORKITEMS to get workitems for the sub-workflows after running the first function module.</font>
<br><font size=3 face="Times New Roman"> </font>
<br><font size=2 face="Arial">But, this just feels like duplication of work, and I can't help feeling that there must be a far more elegant solution lurking out there!</font>
<br><font size=3 face="Times New Roman"> </font>
<br><font size=2 face="Arial">Anyone know what this solution is?</font>
<br><font size=3 face="Times New Roman"> </font>
<br><font size=2 face="Arial">Cheers</font>
<br><font size=3 face="Times New Roman"> </font>
<br><font size=2 face="Arial">Lyal</font>
<p><font size=1 face="Arial">IMPORTANT: This email is intended for the use of the individual addressee(s) named above and may contain information that is confidential, privileged or unsuitable for overly sensitive persons with low self-esteem, no sense of humour or irrational religious beliefs. If you are not the intended recipient, any dissemination, distribution or copying of this email is not authorised (either explicitly or implicitly) and constitutes an irritating social faux pas. Environmentalists will be pleased to know that no animals were harmed in the transmission of this email, and the message is composed of 100% recycled electrons.</font>
<p><font size=1 face="Arial">Those of you with an overwhelming fear of the unknown will be gratified to learn that there is no hidden message revealed by reading this warning backwards or upside-down, so please ignore any conspiracy theories to the contrary. If you have received this email in error, please add some nutmeg and egg whites, whisk and place in a warm oven for 40 minutes. </font>
<p><font size=3 face="Times New Roman"> </font>
<br><font size=3 face="Times New Roman"><br>
<br>
**********************************************************************<br>
This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please notify the system manager.<br>
<br>
This email is sent by a member of the RMC Group p.l.c. group of Companies.<br>
RMC Group p.l.c. is registered in England under company no. 249776. The registered office address of RMC Group and its UK subsidiaries is RMC House, Coldharbour Lane, Thorpe, Egham, Surrey TW20 8TD.<br>
<br>
This footnote also confirms that this email has been swept by MIMEsweeper for the presence of computer viruses.<br>
<br>
www.mimesweeper.com<br>
**********************************************************************</font><font size=2 face="Courier New">_______________________________________________<br>
SAP-WUG mailing list<br>
SAP-WUG@mit.edu<br>
http://mailman.mit.edu/mailman/listinfo/sap-wug<br>
</font>
<br>
<br><FONT SIZE=3><BR>
<BR>
***********************************************************************************<BR>
This message should only be read by those persons to whom it is <BR>
addressed, and may contain confidential information, the disclosure <BR>
of which is prohibited. This message is not intended to create rights <BR>
or obligations without subsequent written confirmation of its contents. <BR>
If you have received this message in error, please notify us immediately <BR>
***********************************************************************************<BR>
</FONT>