Using SAP_WAPI_CREATE_EVENT with BOR event parameters

Mike Pokraka wug at workflowconnections.com
Thu Dec 2 07:10:21 EST 2010


I stand corrected!

As I greatly favour classes over BOR, I haven't used that WAPI for a long
time. That's my excuse and I'm sticking with it! :-)

Cheers,
Mike


On Thu, December 2, 2010 11:24 am, Derek Cheng wrote:
> Hi Mike,
>
> I have managed to use SWOTOBJID to pass on the BOR object into container
> as event parameters.
>
> Like this....., it is working fine.
>
> Data: ls_borobj       TYPE swotobjid.
>
>   ls_emp_key-number = lw_objkey.
>   ls_emp_key-validitybegin  = imp_empuser_begin.
>   ls_borobj-objtype = 'EMPLOYEET'.
>   ls_borobj-objkey = ls_emp_key.
>   ls_borobj-logsys = lw_rfcdest.
>   ls_cont-element = 'EMPLOYEEUSER'.
>   ls_cont-value = ls_borobj.
>   APPEND ls_cont TO lt_cont.
>
> Thanks anyway,
>
> Derek.
>
>
> -----Original Message-----
> From: sap-wug-bounces at mit.edu [mailto:sap-wug-bounces at mit.edu] On Behalf
> Of Mike Pokraka
> Sent: Thursday, December 02, 2010 12:17 PM
> To: SAP Workflow Users' Group
> Subject: RE: Using SAP_WAPI_CREATE_EVENT with BOR event parameters
>
> Not for the WAPIs, they use simple container structures as per your code.
>
> I am also not too sure why your code shouldn't work. Using the event log
> to verify results, try SWUE to raise the event manually with your
> container, and then again in SE37 with the same parameters as you are
> generating in your code, then execute your code with the same data. If all
> that works, then there's something wrong in your WF.
>
> A way to see the event container is to set up an event linkage with
> SWE_EVENT_MAIL as a receiver FM and your userid in the receiver type; you
> will receive the event info and container in your SBWP.
>
> Cheers,
> Mike
>
>
> On Wed, December 1, 2010 10:07 pm, Derek Cheng wrote:
>> Hi Rick and Paul,
>>
>> Thanks for the information, you remind me that I should use SWOTOBJID to
>> pass on the information.
>>
>> Derek.
>>
>> -----Original Message-----
>> From: sap-wug-bounces at mit.edu [mailto:sap-wug-bounces at mit.edu] On Behalf
>> Of Rick Bakker
>> Sent: Wednesday, December 01, 2010 10:43 PM
>> To: SAP Workflow Users' Group
>> Subject: Re: Using SAP_WAPI_CREATE_EVENT with BOR event parameters
>>
>> Hi Derek,
>>
>> You could always include a step which calls TS01200205 (which calls
>> object SYSTEM method GENERICINSTANTIATE)
>>
>> regards
>> Rick Bakker
>> hanabi technology
>>
>> On Thu, Dec 2, 2010 at 8:18 AM, Derek Cheng <XDECH at dongenergy.dk> wrote:
>>> Hi all,
>>>
>>>
>>>
>>> Is that a way to set BOR event parameter on 'input_container' to be
>>> used
>>> on
>>> SAP_WAPI_CREATE_EVENT?
>>>
>>>
>>>
>>> I have the following code within a CLASS, SAP_WAPI_CREATE_EVENT return
>>> '0',
>>> but both BOR objects cannot be seen in the triggered workflow.
>>>
>>> * Assign EmpolyeeUser, EmployeeT to container.
>>>   REFRESH lt_cont.
>>>   CLEAR: ls_cont, ls_emp_key.
>>>   ls_emp_key-number = lw_objkey.
>>>   ls_emp_key-validitybegin  = imp_empuser_begin.
>>>   ls_cont-element = 'EMPLOYEEUSER'.
>>>   ls_cont-value = ls_emp_key.
>>>   APPEND ls_cont TO lt_cont.
>>>
>>>   CLEAR: ls_cont, ls_emp_key.
>>>   ls_emp_key-number = lw_objkey.
>>>   ls_emp_key-validitybegin  = imp_emptime_begin.
>>>   ls_cont-element = 'EMPLOYEET'.
>>>   ls_cont-value = ls_emp_key.
>>>   APPEND ls_cont TO lt_cont.
>>>   CALL FUNCTION 'SAP_WAPI_CREATE_EVENT'
>>>     DESTINATION lw_rfcdest
>>>     EXPORTING
>>>       object_type     = 'BUS1065'
>>>       object_key      = lw_objkey
>>>       event           = 'HIRED'
>>>       commit_work     = 'X'
>>>     IMPORTING
>>>       return_code     = lw_return
>>>     TABLES
>>>       input_container = lt_cont.
>>>
>>>
>>>
>>> Any suggestion?
>>>
>>> __________________________________________
>>>
>>> Best Regards/Med venlig hilsen/Met vriendelijke groet
>>>
>>>
>>>
>>> Derek Cheng
>>>
>>> SAP IS-U/CRM/Workflow Consultant
>>>
>>> Mobile: +45 31602028
>>>
>>>
>>>
>>> _______________________________________________
>>> SAP-WUG mailing list
>>> SAP-WUG at mit.edu
>>> http://mailman.mit.edu/mailman/listinfo/sap-wug
>>>
>>>
>>
>> _______________________________________________
>> SAP-WUG mailing list
>> SAP-WUG at mit.edu
>> http://mailman.mit.edu/mailman/listinfo/sap-wug
>>
>>
>> _______________________________________________
>> SAP-WUG mailing list
>> SAP-WUG at mit.edu
>> http://mailman.mit.edu/mailman/listinfo/sap-wug
>>
>
>
> _______________________________________________
> SAP-WUG mailing list
> SAP-WUG at mit.edu
> http://mailman.mit.edu/mailman/listinfo/sap-wug
>
>
> _______________________________________________
> SAP-WUG mailing list
> SAP-WUG at mit.edu
> http://mailman.mit.edu/mailman/listinfo/sap-wug
>





More information about the SAP-WUG mailing list