<?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: Splitting a XSTRING into a Table in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-a-xstring-into-a-table/m-p/7437453#M1551201</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Use the methods I gave you...And you're correct: Anmol's answer was wrong...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 07 Dec 2010 15:29:30 GMT</pubDate>
    <dc:creator>brad_bohn</dc:creator>
    <dc:date>2010-12-07T15:29:30Z</dc:date>
    <item>
      <title>Splitting a XSTRING into a Table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-a-xstring-into-a-table/m-p/7437449#M1551197</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN __default_attr="14" __jive_macro_name="size"&gt; &lt;STRONG&gt;Hello there everybody&lt;/STRONG&gt;, &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN __default_attr="10" __jive_macro_name="size"&gt; i m facing a real awful problem right now. I'm trying to convert an variable of the type XSTRING to a table of the structure SOLISTI1. The lines of the table are 255 characters long. The XSTRING has an unknown length.

For example

len(XSTRING) = 1913 characters

 lines in table = 8 ((7 x 255) + (1x  128)) 

Is there any FM or any order to transform the XSTRING into this certain table???

Greetings Gollmer

 &lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 07 Dec 2010 14:18:49 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-a-xstring-into-a-table/m-p/7437449#M1551197</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-12-07T14:18:49Z</dc:date>
    </item>
    <item>
      <title>Re: Splitting a XSTRING into a Table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-a-xstring-into-a-table/m-p/7437450#M1551198</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Use the functions of funtion group SCMS_CONV or methods of class CL_BCS_CONVERT among others.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 07 Dec 2010 14:35:06 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-a-xstring-into-a-table/m-p/7437450#M1551198</guid>
      <dc:creator>brad_bohn</dc:creator>
      <dc:date>2010-12-07T14:35:06Z</dc:date>
    </item>
    <item>
      <title>Re: Splitting a XSTRING into a Table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-a-xstring-into-a-table/m-p/7437451#M1551199</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;There is a FM &lt;STRONG&gt;'SX_TABLE_LINE_WIDTH_CHANGE'&lt;/STRONG&gt; for this, &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
 CALL FUNCTION 'SX_TABLE_LINE_WIDTH_CHANGE'
     EXPORTING
        line_width_src              = '268'
       line_width_dst              = '268'
      TABLES
        content_in                  = it_pdf[]
       content_out                 = it_pdfdata[]
*      EXCEPTIONS
*        err_line_width_src_too_long = 1
*        err_line_width_dst_too_long = 2
*        err_conv_failed             = 3
*        OTHERS                      = 4.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This did not worked for me, I developed a code for that&lt;/P&gt;&lt;P&gt;first try this else try this code&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
data : wa_pdf type tline,
       wa_pdfdata type solisti1,
       i type i,
       j type i,
       k type i,
       l type i.
i = 134.
loop at it_pdf into wa_pdf.
 move wa_pdf(i) to wa_pdfdata+j.
  j = j + i.
   if j &amp;gt;= 255.
    append wa_pdfdata to it_pdfdata.
    CLEAR wa_pdfdata.
    clear j.
    k = 134 - i.
    if k &amp;gt; 0.
    move wa_pdf+i(k) to wa_pdfdata+0(k).
    endif.
    j = j + k.
 endif.
l = j + i.
 if l &amp;gt;= 255.
   i = 255 - j.
 else.
   i = 134.
 endif.
endloop.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Anmol.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: anmol112 on Dec 7, 2010 9:46 AM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 07 Dec 2010 14:43:58 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-a-xstring-into-a-table/m-p/7437451#M1551199</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-12-07T14:43:58Z</dc:date>
    </item>
    <item>
      <title>Re: Splitting a XSTRING into a Table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-a-xstring-into-a-table/m-p/7437452#M1551200</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello there anmol,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; my input is an XSTRING variable, not a tlines-table. Do you have any idea how else i can solve my problem?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 07 Dec 2010 14:55:35 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-a-xstring-into-a-table/m-p/7437452#M1551200</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-12-07T14:55:35Z</dc:date>
    </item>
    <item>
      <title>Re: Splitting a XSTRING into a Table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-a-xstring-into-a-table/m-p/7437453#M1551201</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Use the methods I gave you...And you're correct: Anmol's answer was wrong...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 07 Dec 2010 15:29:30 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-a-xstring-into-a-table/m-p/7437453#M1551201</guid>
      <dc:creator>brad_bohn</dc:creator>
      <dc:date>2010-12-07T15:29:30Z</dc:date>
    </item>
    <item>
      <title>Re: Splitting a XSTRING into a Table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-a-xstring-into-a-table/m-p/7437454#M1551202</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Brad,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I looked up the function-group and found the FM "SCMS_XSTRING_TO_BINARY". This piece of code sounds really promising to me. Unfortunately I cannot test this FM under real conditions. But I Think this one solves the problem.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you very much Brad.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Greetings Gollmer&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: GollmerBZ on Dec 7, 2010 4:35 PM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 07 Dec 2010 15:34:50 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-a-xstring-into-a-table/m-p/7437454#M1551202</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-12-07T15:34:50Z</dc:date>
    </item>
    <item>
      <title>Re: Splitting a XSTRING into a Table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-a-xstring-into-a-table/m-p/14117850#M2041936</link>
      <description>&lt;P&gt;&lt;SPAN&gt;&lt;SPAN class=""&gt;SCMS_XSTRING_TO_BINARY is the one.&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 03 Jun 2025 12:40:58 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-a-xstring-into-a-table/m-p/14117850#M2041936</guid>
      <dc:creator>GiGro</dc:creator>
      <dc:date>2025-06-03T12:40:58Z</dc:date>
    </item>
  </channel>
</rss>

