Automating a Decision Task

Bert Caryn bert.caryn at belgacom.be
Wed Sep 22 10:35:53 EDT 2004


Alon,
You can use=0D
 
CALL FUNCTION 'SWW_WI_ADMIN_COMPLETE'
       EXPORTING
            WI_ID                       =3D WI_ID
            RETURN_CODE                 =3D RETURN_CODE
       EXCEPTIONS
            UPDATE_FAILED               =3D 1
            NO_AUTHORIZATION            =3D 2
            INFEASIBLE_STATE_TRANSITION =3D 3
            OTHERS                      =3D 4.
 
 
Regards,
 
Bert Caryn
www.openhr.com
 
 
-----Original Message-----
From: SAP Workflow [mailto:Owner-SAP-WUG at MITVMA.MIT.EDU] On Behalf Of
Alon Raskin
Sent: 22 September 2004 15:04
To: SAP-WUG at MITVMA.MIT.EDU
Subject: Automating a Decision Task
 
Here is what I am trying to do. I am trying to programmatically simulate
a user selecting a particular outcome in a decision task. Its actually
quite simple but the problem is that once I have done that I need the
work item to be removed from the Inbox. Of course the item remains in
READY status as it has not been executed. What I really want to do is
change the status to COMPLETED but I can not do this using the WAPI
because it says it cannot go from status READY to COMPLETED (Fair
enough).=0D
 
What I did then is programtically reserve the work item and then chagne
its status to COMMITED using FM SWW_WI_STATUS_CHANGE_NEW. After doing
that the item changed its status to Completed. While this works, I am a
little nervous manually changing the status of a work item. I was just
wondering if anyone knew a better way?
 
Regards,
 
Alon
 
 
 
**** DISCLAIMER ****
"This e-mail and any attachments thereto may contain information
which is confidential and/or protected by intellectual property
rights and are intended for the sole use of the recipient(s)named above.
Any use of the information contained herein (including, but not limited to,
total or partial reproduction, communication or distribution in any form)
by persons other than the designated recipient(s) is prohibited.
If you have received this e-mail in error, please notify the sender either
by telephone or by e-mail and delete the material from any computer.
Thank you for your cooperation."
 


More information about the SAP-WUG mailing list