Skip to Content
0
Nov 09, 2012 at 03:11 PM

Display Base64 encoded files in cl_gui_html_viewer

957 Views

Dear NG,

I'm searching for a possibility to display files in cl_gui_html_viewer which are Base64 encoded.

My scenario:

I'm calling a WebService via ABAP proxy using the PI infrastructure to receive a document from a remote system (non-SAP).

The document will be fetched, Base64 encoded and provided as XString by the ABAP proxy.

Having the document data as XString, I'd like to pass it to the cl_gui_html_viewer for display, the problem seems to be that the data are encoded and I need to decode them first, before I'm able to split it into smaller pieces, transfer them to an internal table an pass it to the viewer.

How do I decode the XString? I found options to decode a String, or a field type X, but nothing for XString.

Any suggestions?

Thanks a lot in advance.

Regards Harry