cancel
Showing results for 
Search instead for 
Did you mean: 

Workitem ID / Workitem through event Question

Former Member
0 Kudos

Hi I have a requirement that I need to send few details from an ABAP report as a workitem to certain users.Iam using the module 'SWE_EVENT_CREATE' to trigger an event linked to a task which sends the workitem. This is working fine.

I need to send an EXCEL attachment in the same workitem is it possible?

I tried using SAP_WAPI_ATTACHMENT_ADD in the method but didn't know how to retrieve the work item ID in the run time..is there a better way to achieve this requirement or a way to find the work item ID in the method

Thanks for your help!

Larry

Accepted Solutions (0)

Answers (4)

Answers (4)

former_member185167
Active Contributor
0 Kudos

Hello,

Please use SAP_WAPI_CREATE_EVENT and not SWE_EVENT_CREATE (and definitely not SAP_WAPI_START_WORKFLOW).

regards

Rick Bakker

hanabi technology

Former Member
0 Kudos

Hi ,

As Rob suggested go for SO_NEW* function modules if you just want to send mails with attachments to tthe given users.

However if you have some sequence of tasks to be completed after you send mail, you need to create workflow( as it appears you have done). About the Workitem ID , you can use the &_WORKITEM.WORKITEMID& available in the binding and read it using relevant macro .

Regards

Gautam

former_member186746
Active Contributor
0 Kudos

Hi,

What does the workitem do?

Couldnt you just send the attachment though a mail step.

Otherwise you have to create a workflow linked to this event and in the workflow a step to retrieve the correct attachment and then to add it in the binding of the task you're using at the moment.

Kind regards, Rob Dielemans

Former Member
0 Kudos

Hi,

Please use any of follwing Fm to start for the workflow directly. You can find the workitem id in as the export paramenter.

SWW_WI_START_SIMPLE : General Task not required

SWU_START_WORKFLOW : General Task not required

SAP_WAPI_START_WORKFLOW : General Task Required

EWW_WORKFLOW_START : General Task not required

Thanks and regards,

SNJY