Skip to Content
author's profile photo Former Member
Former Member

Get Content of Uploaded File

hello all,

I create a WDA application for uploading files, waht Inned now is a FM that convert/give back the content of this File.

it is not an XML file, it is just normal DATA, but I need this Data in an internal Table.

by Debugging, i cann see this DATA when clicking on XML Broser. but i get it alawys as XSTRING forma.

please show me how solve this. how to get this data in internal table as it is writen on the Files.

thank you very much

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

2 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Dec 11, 2014 at 06:53 AM

    You have to convert XSTRING to STRING. Just search for it and you will find the corresponding fm

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Dec 11, 2014 at 09:04 AM

    Hi,
    You have to supply an encoding to tell the system what codepage/unicode type the XSTRING is.


    data: convin type ref to cl_abap_conv_in_ce,
    call method cl_abap_conv_in_ce=>create
    exporting
    encoding = encoding
    input = buffer
    receiving
    conv = convin.

    call method convin->read
    importing
    data = text_buffer.

    Note : Buffer is the XSTRING, text_buffer is the string.

    Or

    You can use this FM : HR_KR_XSTRING_TO_STRING

    Hope this helps you.

    Thanks

    KH

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.