PDF Attachment to _ATTACH_OBJECT

David Cooper David.G.Cooper at mail.com
Mon Jul 23 09:36:57 EDT 2012


Hi fellow Workflow Experts,

 I am trying to attach a smartform document as a PDF to a workflow User Decision task.

 As such in the binding I have the _ATTACH_OBJECT which is of type SOFM.

 The process for converting the SmartForm to PDF is pretty well layed out online.

 In a BOR object Method I am performing the following steps

 1) Get the function for the SmartForm using function SSF_FUNCTION_MODULE_NAME
 2) Call the SmartForm function retrieving the OTF Data
 3) Convert the OTF Data to PDF using function SX_OBJECT_CONVERT_OTF_PDF
 4) Attaching the PDF Hex data to a SOFM object

 What I am having difficulty with is attaching the PDF HEX data to SOFM.

 When I go to display the attached object it is corrupted. But if I do steps 1 to 3 in a program and download the PDF hex data the file is displayable.

 I have attempted to use the following functions
 SO_DOCUMENT_INSERT
 SO_OBJECT_INSERT
 SAP_WAPI_ATTACHMENT_ADD

 Hoping some kind sole has a working version of the above. Not just sending the PDF as a email attachment!!

Regards

 David Cooper
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.mit.edu/pipermail/sap-wug/attachments/20120723/ee82506c/attachment-0001.htm


More information about the SAP-WUG mailing list