Start workitem immediately within the application

Soady, Phil phil.soady at sap.com
Fri Jun 20 17:26:42 EDT 2003


Yeh Mike you picked up on exactly what I was suggesting...
 
Werner you may need to modify to what you want.
If not a programmer, then you will need help.
 
Determine where SWE_EVENT_CREATE is called.
Is it in the update task ?=20
No, Then the call of SWE_EVENT_CREATE could be changed to include the =
Synchronous flag.
 
Otherwise, in a user exit at save (is there one) or with a =
modification,
you could call the start workflow function directly. This should =
guarantee that no asynchronous
behaviour has started prior to the workflow kicking off. =20
Ie your doing what SWUS does via a function call.=20
Of course you would need to build the container and make it part of the =
call to=20
SAP_WAPI_START_WORKFLOW.
 
 
The event Q can be seen / configured in SWEQADM.
 
hth
 
Phil Soady
Senior Consultant
Business Technologies
SAP Australia
* : 0412 213 079
* : phil.soady at sap.com
 
 
 
 
 
-----Original Message-----
From: Werner K=F6=DFl [mailto:werner.koessl at hirschvogel.de]=20
Sent: Friday, June 20, 2003 11:17 PM
To: SAP-WUG at MITVMA.MIT.EDU
Subject: AW: Start workitem immediately within the application
 
 
Thanks Mike!
 
I will try it and then let you know.
But first i will take a vacation of one week!
 
Happy week-end!
 
 
-----Urspr|ngliche Nachricht-----
Von: SAP Workflow [mailto:Owner-SAP-WUG at MITVMA.MIT.EDU]Im Auftrag von =
Michael Pokraka
Gesendet: Freitag, 20. Juni 2003 14:50
An: SAP-WUG at MITVMA.MIT.EDU
Betreff: Re: Start workitem immediately within the application
 
 
Hi,
That's probably not going to cut it, for the same reasons you're =
already stating :-) SWE_EVENT_CREATE is handled by the event manager, =
who triggers the workflow by tRFC - even if on the same system. RFC =
means WF-BATCH...
 
The next problem is that status management may also happen in an update =
task (most likely in fact), in which case the user context is already =
lost - the user is sitting with a 'document saved' message whilst the =
updates are still making their way into the DB. In this case it isn't =
going to work and an express message is your best bet. If it isn't done =
in an update task, you might get away with starting the workflow =
directly via  (Phil - is this what you intended?). I'm not too sure if =
it will work - let us know if you're going to try it.
 
Cheers
Mike
 
On Fri, Jun 20, 2003 at 10:39:21AM +0200, Soady, Phil wrote:
> Lieber Werner,
>
> if the event is processed and the wf started by WF-BATCH ( a=20
> background )
user,
> then how can the workflow connect back to your modi ?
> And interesting security issue.
>
> The workflow must be started by the current user. Ie no asynchronous
handling.
>
> Any chance of calling swe_event_create synchronously ?
> See the flag on the Function call.
>
> That implies no event Q ? Well, I've never tried synchronous and =
event=20
> q.
>
> At least now, the user should get the user decision.
>
> hth / htw
>
> Cheers
>
>
> Phil Soady
> Senior Consultant
> Business Technologies
> SAP Australia
> * : 0412 213 079
> * : phil.soady at sap.com
>
>
>
>
>
> -----Original Message-----
>> From: Werner Kv_l [mailto:werner.koessl at hirschvogel.de]
> Sent: Friday, June 20, 2003 5:35 PM
> To: SAP-WUG at MITVMA.MIT.EDU
> Subject: Start workitem immediately within the application
>
>
> Hi everyone,
>
> we start one workflow when someone changes the status of a document.=20
> But
the first workitem should be executed immediately after the change of =
the status. (Not only created, but executed!)
>
> The first workitem is a user decision, and the receiver of the first
workitem is WF_INITIATOR. The "Advance with immediate dialog"-field is =
marked in the workflow template and in the first step.
>
> But the workitem does not execute!
>
> Does anybody have an idea?
>
> Regards,
> Werner.
 


More information about the SAP-WUG mailing list