cancel
Showing results for 
Search instead for 
Did you mean: 

Completion of workitem for webdynpro abap application

Former Member
0 Kudos

Hello,

i start a webdynpro abap application from a workitem with BO WEBSERVICE, method PROCESSDIALOG. Terminating event is COMPLETED from BO WEBSERVICE.

After i complete the workitem with FM SAP_WAPI_WORKITEM_COMPLETE in the webdynro application, workitem is processed, but workflow is set to error.

thanks

paul

Accepted Solutions (0)

Answers (4)

Answers (4)

bpawanchand
Active Contributor
0 Kudos

The only way till now I found to handle the WEBSERVICE BO is when ever you finish the job that is associated with the appllication , I mean when the end user clicks on the SUBMIT button the all you have to do is call the terminating event of the WEBSERVICE by using the FM SWE_EVENT_CREATE by passing the object key as workitem ID and BO name as WEBSERVICE and event as COMPLETED and after calling this finally you have to write COMMIT WORK.

Former Member
0 Kudos

Hi,

error message:

Work item 000000400230: Object FLOWITEM method EXECUTE cannot be executed

Error when defining successor for node 0000000036

Error during result processing of work item 000000400232

Error when defining successor for node 0000000036.

If i use the FM SWE_EVENT_CREATE i get a message 'Event created - no receiver found'. I assume, the problem is that in the container for workitem a webservice object is not instantiated. How can i instantiate this WEBSERVICE object? I thought it must be instantiated by workflow automatically.

thanks

Paul

surjith_kumar
Active Contributor
0 Kudos

Hi,

Can you check in T.code SWU3, the workflow customizing is done or not.

If this done, Execute the BO separate and see it working fine. If you created a subtype of the std. BO and if the delegation not done correctly, this will happen.

Regards,

Surjith

pokrakam
Active Contributor
0 Kudos

Hi Paul,

I think the error is a red herring and has little to do with the webservice business. If you manually execute SAP_WAPI_WORKITEM_COMPLETE from SE37, do you get the same error? And what if oyu complete it manually by editing the WI? If you still get the error in these scenarios your WF may be corrupt, deleting and recreating the step may help.

Cheers,

Mike

Former Member
0 Kudos

If i complete it manually, it works (but not via SAP_WAPI_WORKITEM_COMPLETE)

If i set a dummy workitem ID in WEBSERVICE BO and execute SWE_EVENT_CREATE it also works fine.

regards

Paul

pokrakam
Active Contributor
0 Kudos

>

> If i complete it manually, it works (but not via SAP_WAPI_WORKITEM_COMPLETE)

> If i set a dummy workitem ID in WEBSERVICE BO and execute SWE_EVENT_CREATE it also works fine.

>

> regards

> Paul

Try reserving the work item first - there's a WAPI for it.

Ignore the event, that's a little bit special and relies on the WSHANDLER service which you are probably not using if you're using a later version of the UWL. You can add your own BO to the task and use that as a terminating event instead.

Former Member
0 Kudos

Hello,

I use now usual BO with display-Method instead of webservice BO. I made settings in SWFVISU, but SAP GUI dialoge is already executed. Must i check some additional settings - maybe transaktion WF_HANDCUST or some customizing tables?

Regards

Paul

pokrakam
Active Contributor
0 Kudos

No, I meant add another BO to the task as a container element and use that for your terminating event. The task itself can (and should) stay based on WEBSERVICE.

Former Member
0 Kudos

Hello Mike,

Blog /people/ginger.gatling/blog/2005/12/14/create-new-uis-for-existing-workflow-tasks-with-abap-web-dynpro-and-universal-worklist :

"Our object type is WEBSERVICE, however, it does not have to be WEBSERVICE. Since the ABAP Web Dynpro will receive the work item ID at runtime and will access the container, the object and method can be anything."

I assume transaction SWFVISU can be used to replace SAP GUI call with WEB DYNPRO, in best case without changing the workflow. If it is the case, normally synchron display-method is used.

Regards

Paul

pokrakam
Active Contributor
0 Kudos

Partly correct, it will work with anything since it's the visualization that controls what is launched from the UWL.

However WEBSERVICE is better because it will also work nicely from SBWP, the wizard will generate it for you and there are a few other minor tweaks.

On the other hand, using another method will give you the possibility of launching something completely different from SBWP. All depends on what you need to do.

Former Member
0 Kudos

Hello Mike,

does it mean SWFVISU is only used for UWL and i must use WF_EXTSRV wizard for SBWP?

I thought entries in SWFVISU must also have influence on workitems in SBWP.

Regards

Paul

bpawanchand
Active Contributor
0 Kudos

WF_EXTSRV is used to define the external services like if at all you want to open a BSP application then you can make use of this external service definition, evenn you can define for WD applications too. But in general we register the application with a task and associate these two in the swfvisu txn. by using this your Portal guys will register the task from the UWL side by passing the properties based on the type of Visualization type.

Former Member
0 Kudos

if i register a WD Application via tx SWFVISU, start it in UWL and complete a workitem via SAP_WAPI_WORKITEM_COMPLETE it works.

I try to start a WD Application also in Bussines Workplace. Task was generated with WF_EXTSRV and based on WEBSERVICE BO. If i try to complete a workitem via SAP_WAPI_WORKITEM_COMPLETE a workitem is completed but workflow is set to error. Therefore i thought it would be better if it were possible to start a WD from workitem in Bussines Workplace also with the tx SWFVISU. But it is not working.

Regards

Paul

bpawanchand
Active Contributor
0 Kudos

If it is a decision task i mean if the application result is a boolean result TRUE/ FALSE or APPROVE/ REJECT /REVIEW then instead of using the SAP_WAPI_WORKITEM_COMPLETE use the FM SAP_WAPI_DECISION_COMPLETE by passing the decision key as 0001 for apporve 0002 for reject or 0003 for review.

surjith_kumar
Active Contributor
0 Kudos

Hi,

Can you tell what error message you getting the workflow log.

Regards,

Surjith

pokrakam
Active Contributor
0 Kudos

Posting the error message always helps...

vijy_mukunthan
Active Contributor
0 Kudos

Hi paul

Go to SWIA check the log and tell what is the error your are getting.

Regards

vijay