‎2007 Jun 19 1:46 PM
I have been tasked with extracting data from external attachments from the 'services for object' button. I am working in an sap 4.7 environment. I have not found any tips on how to do this from google searches.
Here is an example. If you look at most of the major documents (purchase order, invoice, delivery, etc.) there will be a little dropdown icon in the upper left corner of the screen (check out page 1 of this file - http://www.le.ac.uk/mis/docs/sapdocs/ug/UG5-1%20Services.doc)
That icon is the 'Services for Object' button. Clicking on it will display a small popup window with several options including one for attached documents.
If an attachment (could be word, excel, pdf, URL, etc.) exists it will show up and can be viewed by double clicking on it. Does anyone know how to access
that attachment programatically?
Thank you very much in advance.
Glenn Allen
Software Architect (specializing in SAP)
‎2007 Jun 19 5:41 PM
Hi,
Please check the following method to get binary data from GOS
[code]
is_object-instid = v_bo_id.
is_object-typeid = v_botype.
is_object-catid = 'BO'.
try.
call method cl_binary_relation=>read_links_of_binrel
exporting
is_object = is_object
ip_relation = 'ATTA' " << I think it will ATTA or MESSAGE i am confused
importing
et_links = et_links.
then use
call function 'SREL_GET_NEXT_RELATIONS'
exporting
object = lo_is_object_a
ROLETYPE =
relationtype = p_reltyp
MAX_HOPS = 1
INCL_APPLRELS = ' '
EXCL_ROLES =
EXCL_RELATIONS =
tables
links = lt_links
ROLES =
APPLLINKS =
exceptions
internal_error = 1
no_logsys = 2
others = 3
if not worked then try
fm BDS_BUSINESSDOCUMENT_GET_TAB
and also check the following link.
https://www.sdn.sap.com/irj/sdn/wiki?path=/display/snippets/abap-SendingGOSattachmentstoanemailaddress&
aRs
Message was edited by:
aRs