<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Convert XSTRING to TEXT in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/convert-xstring-to-text/m-p/8992219#M1697320</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Jorg/Rudger,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm not sure how to answer. These XLS files were probably uploaded to BPC so I would say it contains more than the cell contents.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can you tell the steps to transform this XSTRING to the cell contents so I can create a CSV?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Alex.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 17 Aug 2012 18:14:17 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2012-08-17T18:14:17Z</dc:date>
    <item>
      <title>Convert XSTRING to TEXT</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/convert-xstring-to-text/m-p/8992212#M1697313</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello all,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I've been trying to convert a variable declared as xstring into TEXT, but after trying many function modules, I'm still without a solution.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My program reads an XLS file from BPC and the contents returns in a XSTRING variable. Since they need this file saved into the App.Server as CSV, I have to transform the spreadsheet into text first.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any ideas?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;JF&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 16 Aug 2012 20:37:10 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/convert-xstring-to-text/m-p/8992212#M1697313</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2012-08-16T20:37:10Z</dc:date>
    </item>
    <item>
      <title>Re: Convert XSTRING to TEXT</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/convert-xstring-to-text/m-p/8992213#M1697314</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;does the XSTRING only contain the content of your excel file, or does it contain the binary representation of the file itself? EG, does it have the excel file's metadata etc in it as well... &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Have you tried calling method:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: 'Courier New'; background-color: #ffffff;"&gt;CL_ABAP_CONV_IN_CE=&amp;gt;CREATE&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 16 Aug 2012 22:52:50 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/convert-xstring-to-text/m-p/8992213#M1697314</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2012-08-16T22:52:50Z</dc:date>
    </item>
    <item>
      <title>Re: Convert XSTRING to TEXT</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/convert-xstring-to-text/m-p/8992214#M1697315</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Jorg,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;this is the method called within function 'CONVERT_XSTRING_TO_TEXT', which I had already tried with no success.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Alex.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Aug 2012 02:10:13 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/convert-xstring-to-text/m-p/8992214#M1697315</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2012-08-17T02:10:13Z</dc:date>
    </item>
    <item>
      <title>Re: Convert XSTRING to TEXT</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/convert-xstring-to-text/m-p/8992215#M1697316</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;check out this link&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&amp;lt;link farm removed&amp;gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope it helps!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: Suhas Saha&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Aug 2012 04:03:54 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/convert-xstring-to-text/m-p/8992215#M1697316</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2012-08-17T04:03:54Z</dc:date>
    </item>
    <item>
      <title>Re: Convert XSTRING to TEXT</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/convert-xstring-to-text/m-p/8992216#M1697317</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hiii,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Try this 2 FM -&amp;nbsp; &lt;STRONG&gt;SCMS_XSTRING_TO_BINARY&lt;/STRONG&gt; than &lt;STRONG&gt;SCMS_BINARY_TO_TEXT &lt;/STRONG&gt;.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Aug 2012 05:01:44 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/convert-xstring-to-text/m-p/8992216#M1697317</guid>
      <dc:creator>Aashish28</dc:creator>
      <dc:date>2012-08-17T05:01:44Z</dc:date>
    </item>
    <item>
      <title>Re: Convert XSTRING to TEXT</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/convert-xstring-to-text/m-p/8992217#M1697318</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Julio &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;In My example shown below 'buffer' is the XSTRING, 'text_buffer' is the string. You have to supply an encoding to tell the system what codepage/unicode type the XSTRING is. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data: convin&amp;nbsp; type ref to cl_abap_conv_in_ce,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; call method cl_abap_conv_in_ce=&amp;gt;create&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; exporting&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; encoding&amp;nbsp;&amp;nbsp;&amp;nbsp; = encoding&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; input&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; = buffer&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; receiving&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; conv&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; = convin.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; call method convin-&amp;gt;read&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; importing&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; data = text_buffer.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please revert back.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Aaradhana&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Aug 2012 05:49:21 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/convert-xstring-to-text/m-p/8992217#M1697318</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2012-08-17T05:49:21Z</dc:date>
    </item>
    <item>
      <title>Re: Convert XSTRING to TEXT</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/convert-xstring-to-text/m-p/8992218#M1697319</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;JF,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;as far as I see, you didn't answer Jorg's question&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;P&gt;does the XSTRING only contain the content of your excel file, or does it contain the binary representation of the file itself?&lt;/P&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;This is crucial. It should be clear: if you upload an XLS or XLSX file to the server, you cannot simply use a character converter to transform the XSTRING representing this file&amp;nbsp; into a string and expect a csv string as result. XLS is encoded in the &lt;A href="http://www.openoffice.org/sc/excelfileformat.pdf"&gt;BIFF &lt;/A&gt;format, whereas XLSX is a zipped &lt;A href="http://en.wikipedia.org/wiki/Office_Open_XML"&gt;OpenXML&lt;/A&gt; file. Both formats contain a lot of data, not only the cell contents.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For transforming an Excel file into a csv stringtab, the following steps are necessary:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;The file has to be &lt;EM&gt;parsed&lt;/EM&gt; first, &lt;/LI&gt;&lt;LI&gt;and from the parsed model you can &lt;EM&gt;extract the data&lt;/EM&gt; you want &lt;/LI&gt;&lt;LI&gt;and finally &lt;EM&gt;build&lt;/EM&gt; the desired csv.&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you answer Jorg's question, we can help you with specific classes or function modules that are doing this work for you.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rüdiger&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Aug 2012 06:30:14 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/convert-xstring-to-text/m-p/8992218#M1697319</guid>
      <dc:creator>Ruediger_Plantiko</dc:creator>
      <dc:date>2012-08-17T06:30:14Z</dc:date>
    </item>
    <item>
      <title>Re: Convert XSTRING to TEXT</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/convert-xstring-to-text/m-p/8992219#M1697320</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Jorg/Rudger,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm not sure how to answer. These XLS files were probably uploaded to BPC so I would say it contains more than the cell contents.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can you tell the steps to transform this XSTRING to the cell contents so I can create a CSV?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Alex.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Aug 2012 18:14:17 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/convert-xstring-to-text/m-p/8992219#M1697320</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2012-08-17T18:14:17Z</dc:date>
    </item>
  </channel>
</rss>

