on 04-18-2018 11:11 AM
Hi,
I have a pdf file in my local machine and i have to send it to my work item (user decision and/or mail) as an attachment. I have a module pool program wherein im uploading this to internal table using gui_upload fm in binary format nad then setting my event container which then binded with workflow container. im using data type as solix_tab and my code is as below:
SPAN {
font-family: "Courier New";
font-size: 10pt;
color: #000000;
background: #FFFFFF;
}
.L0S31 {
font-style: italic;
color: #808080;
}
.L0S33 {
color: #4DA619;
}
.L0S52 {
color: #0000FF;
}
.L0S55 {
color: #800080;
}
.L0S70 {
color: #808080;
}
DATA: WF_DOC1 TYPE SOLIX_TAB, WF_LEN1 TYPE INT4, GV_FILE TYPE STRING.
GV_FILE = GV_PATH1.
CALL FUNCTION 'GUI_UPLOAD'
EXPORTING
FILENAME = GV_FILE "P_FILE
FILETYPE = 'BIN'
IMPORTING
FILELENGTH = WF_LEN1
** HEADER =
TABLES
DATA_TAB = WF_DOC1.
LV_PARAM_NAME = 'WF_DOC1'.
CALL METHOD LR_EVENT_PARAMETERS->SET
EXPORTING
NAME = LV_PARAM_NAME
VALUE = WF_DOC1.
LV_PARAM_NAME = 'WF_LEN1'.
CALL METHOD LR_EVENT_PARAMETERS->SET
EXPORTING
NAME = LV_PARAM_NAME
VALUE = WF_LEN1.
CATCH CX_SWF_CNT_CONT_ACCESS_DENIED .
CATCH CX_SWF_CNT_ELEM_ACCESS_DENIED .
CATCH CX_SWF_CNT_ELEM_NOT_FOUND .
CATCH CX_SWF_CNT_ELEM_TYPE_CONFLICT .
CATCH CX_SWF_CNT_UNIT_TYPE_CONFLICT .
CATCH CX_SWF_CNT_ELEM_DEF_INVALID .
CATCH CX_SWF_CNT_CONTAINER .
ENDTRY.
*Raise the event
TRY.
CALL METHOD CL_SWF_EVT_EVENT=>RAISE
EXPORTING
IM_OBJCATEG = CL_SWF_EVT_EVENT=>MC_OBJCATEG_CL
IM_OBJTYPE = LV_OBJTYPE
IM_EVENT = LV_EVENT
IM_OBJKEY = LV_OBJKEY
IM_EVENT_CONTAINER = LR_EVENT_PARAMETERS. ""lo_ref_parameters.
ENDTRY.
COMMIT WORK.
ENDIF.
However on execution, when im checking workflow container values are not setting up. Is there any issue with binary format values or something else. Could anybody please advise.
Thank you !
Made further changes based on this link and its fine now.
http://saptechnical.com/Tutorials/Workflow/Class/Multiline2.htm
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
83 | |
24 | |
12 | |
9 | |
7 | |
6 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.