cancel
Showing results for 
Search instead for 
Did you mean: 

Subscribe for an Event

Former Member
0 Kudos

Hi all,

Instead of using an BADI or UserExit, I want to react on an triggered event.

If someone creates or changes a Business Partner I want to call a function module or a method after this event.

How can I do this?

Is there something in workflow customizing available, where I can specify which function module should be called

after an specific event is triggered?

Thanks for any help in advance.

regards, Hans

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hello Hans,

Check transaction SWETYPV. In that transaction you link the event and workflow together (I am sure you already knew this?). The you can also define so called check function module. This function module needs to have certain parameters in order to work, so check one of the already existing entries in SWETYPV to find out the correct parameters for you function module. And in this function modules you can do of course whatever you want... (well, not everything).

Also, check through the SAP help regarding workflow check function modules.

Regards,

Karri

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Hans, you can go to swe2 and find related workflow linkage, there is one field where you can specify check function module which is orignally used for restricting the event to trigger workflow. If there is any exception, then, the event will not trigger the workflow. However, you can also do whatever you want in this function module.

Former Member
0 Kudos

There's no rule that says a workflow must have user interaction. I often create simple workflows with the purpose of responding to events and performing some background processing.

You could extend the Business Partner with a method that calls your desired function module.

Create a Standard Task for the new method and then insert that standard task into a new Workflow Template.

Set the event(s) of the Business Partner as the Starting Event of the new Workflow Template.

(This all could also be accomplished without creating the workflow template by associating the triggering event directly with the Standard Task. It's commonly referred to as a "Single Step Workflow").

Hope this is relevant.

Tom Carruth