Skip to Content

How to Convert Unreadable format of Content into Readable string format ?

Hello Experts,

I have Base64 Content and i need to change it in original format using ABAP. Here i am attaching one pic for that content.

How to change this content into Readable format...

I am new to this concept so that i am not confirm whether this is Base64 Format or not .

So ultimately i need to change the above format in any of our understandable format using ABAP Coding.

Thanks,

Vamsi.

base.jpg (705.9 kB)
Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Best Answer
    Dec 27, 2016 at 02:30 PM

    It looks like a "MIME base64 string" (possible characters ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/ and there may be = in the last two characters). More information at wikipedia: MIME#Content-Transfer-Encoding.

    For decoding it into a XSTRING variable, you may use the function modue SSFC_BASE64_DECODE.

    Add comment
    10|10000 characters needed characters exceeded

    • Hi Rossi,

      Yes you said right.Thank you so much...

      First i convert my BASE64 string into XSTRING then From XSTRING to Binary format and i used that Binary format in GUI_DOWNLOAD. At last it downloaded as JPG Format.

      Thanks,

      Vamsi.

  • Dec 28, 2016 at 05:44 AM

    Hi Rossi,

    Thanks for the Reply...

    I Decoded my Base64 Content then i am getting as like below screen shot...

    Now what should we do with this above code, In the above code i understand only one line i.e., One link with .JPG and rest of the code shown as special characters...

    Could you please guide me....

    Thanks,

    Vamsi

    Add comment
    10|10000 characters needed characters exceeded

    • Base64 is a text format for transferring bytes. Bytes cannot be read. As far as I can read, it's a JPG format. You just need to transfer these bytes to a file in binary mode, and open this file using a JPG viewer.