‎2008 Jul 08 7:22 AM
Hello all,
I've a report program, the output of whch is an internal table with a single field type c. (elementary internal table). I've schedule the program to run at a specific time in background. Now, whenever the program executes, I want a workflow to trigger and pass the entire internal table to the workflow. How do I achieve this? Please help me out.
Regards
Indu.
‎2008 Jul 08 7:34 AM
‎2008 Jul 08 7:34 AM
‎2008 Jul 08 7:49 AM
Peter,
could you please give an example as of how i pass the internal table to that FM.
Indu.
‎2008 Jul 14 4:08 AM
hi,
here is an example
CONSTANTS : gc_task LIKE swwwihead-wi_rh_task VALUE 'WS99900152'.
DATA : BEGIN OF it_swcont OCCURS 0.
INCLUDE STRUCTURE swcont.
DATA : END OF it_swcont.
MOVE : 'MATERIALRESERVATION' TO it_swcont-element,
090 TO it_swcont-elemlength,
'o' TO it_swcont-type.
CONCATENATE sy-sysid 'CLNT' sy-mandt
'BUS2093' 'XXX' gd_rsnum INTO
it_swcont-value.
REPLACE 'XXX' WITH ' ' INTO it_swcont-value.
APPEND it_swcont. CLEAR it_swcont.
MOVE : '_WF_INITIATOR' TO it_swcont-element,
014 TO it_swcont-elemlength,
'C' TO it_swcont-type,
gd_creator TO it_swcont-value.
APPEND it_swcont. CLEAR it_swcont.
*---------------------------------------
*-------get work item type
CALL FUNCTION 'RH_GET_WORKITEM_TYPE'
EXPORTING
task_object = gc_task
IMPORTING
wi_type = gd_type.
*----------------------------------------
*----start workflow ---------------------
CALL FUNCTION 'SWW_WI_START'
EXPORTING
creator = gd_creator
task = gc_task
workitem_type = gd_type
IMPORTING
wi_id = gd_id
TABLES
wi_container = it_swcont.