on 04-12-2010 7:17 AM
Hi friends,
I am using program exit in my workflow. While using this class, I am able to use the value of container which is flowing in my workflow but How can I use a container which is of type some business object. Say I am using a container DRAW type business object DRAW. I want to use the values flowing in the container DRAW. Please guide.
Thanks,
Gaurav
Check out this [article|http://wiki.sdn.sap.com/wiki/display/ABAP/Program%20Exits%20In%20Workflow]
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
After read the value of the BOR object DRAW by using the method Get mehtod...
Beofre using the belwo code snippet you have to make sure that you have included the INCLUDE cntn01_swc in the
Utilities ---> call-locval types ---> Macros ---> Include cntn01_swc.
DATA: lv_draw type swc0_object.
DATA: lv_status type char32.
SWC0_GET_PRORPERTY lv_draw 'STATUS' lv_status.
IF at all the get method is reading the container element then by using the below code snippet you can get the status property of the Draw object....
Hi Gaurav
Try the below code:
Data: data1 type SWC_OBJECT,
lt_container type table of swcont.
call method container->get
Exporting
name = 'DRAW' u201CB.O. used in workflow
importing
VALUE = data1.
CALL FUNCTION 'SWO_INVOKE'
EXPORTING
ACCESS = 'G'
OBJECT = data1-handle
VERB = 'DocumentStatus'
TABLES
CONTAINER = lt_container
lt_container will then have the attribute with the data.
That means the DRAW bor isnot getting populated or there could be a possibility that the name might be different in thewo0rkflow container......make sure that you use the same name what you have deifned in the workflow container.....
Until the Lv_draw is populated property status can not be read.
Hello,
For an object instance, all you need is the object type (eg DRAW) and the key to get passed. After that you should be able to instantiate the object and access all of its attributes.
regards
Rick Bakker
Hanabi Technology
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Gautham,
You can use the FM, SAP_WAPI_READ_CONTAINER to read the container values based on workitem ID.
Thanks.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
93 | |
10 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.