‎2011 Aug 01 3:34 PM
Hi I have an Excel binary field type XSTRING (made with abap2xlsx) and I wanted to convert it in solix_tab in order to use the method add_attachment :
document->add_attachment(
i_attachment_type = 'xls'
i_attachment_subject = 'ExampleSpreadSheet'
i_att_content_hex = binary_content ).
I used this :
CALL FUNCTION 'SCMS_XSTRING_TO_BINARY'
EXPORTING
buffer = lv_reportfile
TABLES
binary_tab = binary_content.
But it didn't work, In result I have plenty of special chars in my Excel sheet.
How should I convert it to the right format ?
Thanks !
‎2011 Aug 01 3:48 PM
Hello Benjamin,
You can use the method "cl_bcs_convert=>txt_to_solix or cl_bcs_convert=>XSTRING_TO_SOLIX " for appending entries into the table solix_tab .
For all conversion related logic SAP provided this utility class "cl_bcs_convert".
This will work.
Let me know if you have any questions.
Thanks,
Greetson
Edited by: Greetson Shunmugasundaram on Aug 1, 2011 4:50 PM
‎2011 Aug 01 3:48 PM
Hello Benjamin,
You can use the method "cl_bcs_convert=>txt_to_solix or cl_bcs_convert=>XSTRING_TO_SOLIX " for appending entries into the table solix_tab .
For all conversion related logic SAP provided this utility class "cl_bcs_convert".
This will work.
Let me know if you have any questions.
Thanks,
Greetson
Edited by: Greetson Shunmugasundaram on Aug 1, 2011 4:50 PM