Workflow Coding

Nat 4 Govender ngovender4 at toyota.co.za
Wed Dec 10 23:38:53 EST 2008


Hi all,


I am faced with the current issue.

I have given one of our ABAPers some workflow code to user in his program
however it does not work in his program.

Extracts from program :


INCLUDE <cntn01>  .
  DATA  : ls_sen_man    LIKE  TABLE OF  swhactor  WITH  HEADER LINE.
  DATA  : initiator     LIKE  wfsyst-agent.
  DATA  : o_role        TYPE  swc_object.
  DATA  : rel_obj       TYPE swc_object.
  data  : REL_CODE      type swc_object.

data : rule_AGENTs  TYPE WFSYST-AGENT OCCURS 0 with header line.

  CONCATENATE 'US' zind_mm01-requested_by INTO initiator.

  SWC_CREATE_OBJECT REL_CODE 'Z_REL_CODE' 'R113'.

  SWC_GET_property REL_CODE 'ReleaseCode' rel_obj.

  swc_container   b_container.
  swc_set_element b_container   'ReleaseCode'   rel_obj.
  swc_set_element b_container   'Org_Agent'       initiator.
  swc_create_object o_role    'Z_STD_ROLE'    'AC90000008'.
  swc_call_method o_role    'ResolveRole'   b_container.
  swc_get_table   b_container   'ActorTab'    rule_AGENTs.

  READ TABLE rule_AGENTs INDEX 1.
  manager = rule_AGENTs .




Extract from code in we have in one of the methods of our objects

DATA:
  AGENT TYPE WFSYST-AGENT OCCURS 0 with header line,
  SUBORDINATE TYPE WFSYST-AGENT OCCURS 0 with header line,
  rel_obj  type swc_object,
  o_rule type swc_object,
  rule_AGENTs  TYPE WFSYST-AGENT OCCURS 0 with header line,
  final_agents TYPE WFSYST-AGENT OCCURS 0 with header line,
  final_tmp    TYPE WFSYST-AGENT OCCURS 0 with header line,
  V_REL_CODE_REQ(4),
  V_BSC_REL_CODE(4),
  REL_LEV_REQ type i,
  REL_LEV_BSC type i,
  bsc_validate like pa0105-flag1.

  SWC_GET_ELEMENT CONTAINER 'ReleaseCode' rel_obj.
  SWC_GET_TABLE CONTAINER 'Agent' AGENT.


SWC_CREATE_CONTAINER rule_cont.
SWC_SET_ELEMENT rule_cont 'ReleaseCode' rel_obj.
SWC_SET_ELEMENT rule_cont 'Org_Agent'   agent.
SWC_CREATE_OBJECT O_RULE 'Z_STD_ROLE' 'AC90000008'.
SWC_CALL_METHOD   O_RULE 'ResolveRole' rule_cont.



There seems be a problem when we pass the details for the object.

Can some one help in identifying what we are doing wrong.











Regards

Nat Govender
Toyota South Africa
IT - SAP Workflow Specialist
Internal Ext.   : 32645
Direct Line    :  +27 031 910 2645
Fax               : +27 031 910 4964 / 031 902 9633 / 086 607 0414
E-mail           :  ngovender4 at toyota.co.za

If you tell the truth, you don't have to remember anything.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.mit.edu/pipermail/sap-wug/attachments/20081211/60465bd2/attachment.htm


More information about the SAP-WUG mailing list