<?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: abap  -  go back to loop iteration in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/abap-go-back-to-loop-iteration/m-p/4269683#M1018810</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If it is inside perform then you can use EXIT and a flag.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;loop at itab.

perform check_something.
if v_flag = 'X'.
 continue.
endif.

endloop.

form check_something.
clear v_flag.

read ....
read....
message.
v_flag = 'X'.
exit.

endform.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Vijay Babu Dudla&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 09 Aug 2008 10:42:06 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-08-09T10:42:06Z</dc:date>
    <item>
      <title>abap  -  go back to loop iteration</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/abap-go-back-to-loop-iteration/m-p/4269679#M1018806</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;i have developed a report in that there is a loop and inside loop there are many read statements and messages.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;my querry is, whenever any message pop up i.e. when that condition fails, the loop should go to next iteration i.e. if the condition has failed in 2nd sy-tabix then immediately the loop should start and it should start from 3rd iteration.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;tabix = 0.&lt;/P&gt;&lt;P&gt;loop at itab.&lt;/P&gt;&lt;P&gt;read statement&lt;/P&gt;&lt;P&gt;read statement &lt;/P&gt;&lt;P&gt;message &lt;/P&gt;&lt;P&gt;what should i write here stop or exit or var = x &lt;/P&gt;&lt;P&gt;read statement&lt;/P&gt;&lt;P&gt;message &lt;/P&gt;&lt;P&gt;what should i write here stop or exit or var = x &lt;/P&gt;&lt;P&gt;read statement&lt;/P&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;from message it should go to next iteration of the loop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanx in adv&lt;/P&gt;&lt;P&gt;manoj&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 09 Aug 2008 10:10:31 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/abap-go-back-to-loop-iteration/m-p/4269679#M1018806</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-08-09T10:10:31Z</dc:date>
    </item>
    <item>
      <title>Re: abap  -  go back to loop iteration</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/abap-go-back-to-loop-iteration/m-p/4269680#M1018807</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Use CONTINUE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;loop at itab.&lt;/P&gt;&lt;P&gt;read statement&lt;/P&gt;&lt;P&gt;read statement &lt;/P&gt;&lt;P&gt;message &lt;/P&gt;&lt;P&gt;CONTINUE.&lt;/P&gt;&lt;P&gt;read statement&lt;/P&gt;&lt;P&gt;message &lt;/P&gt;&lt;P&gt;CONTINUE.&lt;/P&gt;&lt;P&gt;read statement&lt;/P&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 09 Aug 2008 10:15:38 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/abap-go-back-to-loop-iteration/m-p/4269680#M1018807</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-08-09T10:15:38Z</dc:date>
    </item>
    <item>
      <title>Re: abap  -  go back to loop iteration</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/abap-go-back-to-loop-iteration/m-p/4269681#M1018808</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;PRE&gt;&lt;CODE&gt;tabix = 0.
loop at itab.
read statement
read statement 
message 
continue.
"use continue
"what should i write here stop or exit or var = x 
read statement
message 
"continue.
what should i write here stop or exit or var = x 
read statement
endloop.&lt;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 09 Aug 2008 10:15:47 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/abap-go-back-to-loop-iteration/m-p/4269681#M1018808</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-08-09T10:15:47Z</dc:date>
    </item>
    <item>
      <title>Re: abap  -  go back to loop iteration</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/abap-go-back-to-loop-iteration/m-p/4269682#M1018809</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;actually these messages are inside perform statements, so inside perform there is no loop and therefore 'continue' will not work there.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;manoj&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 09 Aug 2008 10:29:13 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/abap-go-back-to-loop-iteration/m-p/4269682#M1018809</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-08-09T10:29:13Z</dc:date>
    </item>
    <item>
      <title>Re: abap  -  go back to loop iteration</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/abap-go-back-to-loop-iteration/m-p/4269683#M1018810</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If it is inside perform then you can use EXIT and a flag.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;loop at itab.

perform check_something.
if v_flag = 'X'.
 continue.
endif.

endloop.

form check_something.
clear v_flag.

read ....
read....
message.
v_flag = 'X'.
exit.

endform.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Vijay Babu Dudla&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 09 Aug 2008 10:42:06 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/abap-go-back-to-loop-iteration/m-p/4269683#M1018810</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-08-09T10:42:06Z</dc:date>
    </item>
  </channel>
</rss>

