Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

EXIT

Former Member
0 Kudos

Hi,

I have a scenario where in a inbound function module, i need to stop idoc processing at some place if an condition is not met.

If i use exit it either exits the current loop or block.

Any command to stop whatever may be the processing after that.

if i have 1000 lines of code and in the 5th line if i issue some command, it shouldn't process remaining lines

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Hi Krishnan,

Use '<b>STOP</b>' statement.

STOP is followed immediately by the END-OF-SELECTION processing. If you do not want this, you may have to use EXIT instead.

Regards,

Rajasekhar

4 REPLIES 4

Former Member
0 Kudos

Hi Krishnan,

Use '<b>STOP</b>' statement.

STOP is followed immediately by the END-OF-SELECTION processing. If you do not want this, you may have to use EXIT instead.

Regards,

Rajasekhar

Former Member
0 Kudos

Control the command with an If statement,Exit should take you out of the block, but normally you must not use an exit in such conditions. Put a flag and set it accordingly and check it using the IF-ENDIF clause,

Hope it helps

christian_wohlfahrt
Active Contributor
0 Kudos

Hi!

stop.
leave program.
message ... type x.

Have a look into command help for details, first one still executes printout, last one is short-dump.

Regards,

Christian

ralf_geiger
Explorer
0 Kudos

Hi Anandha,

you can use the command

RETURN.

to leave the current processed function module or method. Just the same behavior like in Java. I think this command came not a long time ago but it works fine

Regards,

Ralf