Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

How to add notes to an object without a pop-up display like GOS_ATTACHMENT_LIST_POPUP function does?

sbslmhmt
Participant
0 Kudos
279

Hello,

As you know below code opens a pop-up and user can add notes or attachments to an object. I have a string and I want to add this string as a note to object without opening a pop up. Anyone knows any fm or class for this purpuse?

DATA:

gs_object TYPE sibflporb,

lv_req TYPE sgs_flag,

lv_mod TYPE c VALUE 'E',

gv_object(16) TYPE c.


CLEAR gv_object.
CONCATENATE 'XXXXXXXXXX' 'XXXXXX' INTO gv_object.
gs_object-instid = gv_object.

gs_object-typeid = 'XXXX'.

gs_object-catid = 'BO'.

CALL FUNCTION 'GOS_ATTACHMENT_LIST_POPUP'

EXPORTING

is_object = gs_object

ip_notes = 'X'

ip_attachments = 'X'

ip_urls = ' '

ip_mode = lv_mod

IMPORTING

ep_save_request = lv_req.


IF lv_req = 'X'. COMMIT WORK.

ELSE. ROLLBACK WORK. ENDIF.

Best regards.

0 REPLIES 0