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: 

How to call a abap program ?

Former Member
0 Kudos

Can anyone tell me how to call one abap program in another abap program ??

1 ACCEPTED SOLUTION

Former Member
0 Kudos
8 REPLIES 8

Former Member
0 Kudos

Hi,

Look at the SUBMIT statement. It has a lot of options to call an ABAP program of type 1 (report).

Regards,

Arjan

athavanraja
Active Contributor
0 Kudos

<b>submit</b>

check out ABAP key word documentation for <b>SUBMIT</b>

there are different ways, tell us your exact requirement.

Regards

Raja

Former Member
0 Kudos

hi,

try

SUBMIT zzzprog.

but if you only want to call a FORM in an other program

try,

PERFORM name_of_the_form in PROGRAM name_of_the_main_program.

jayanthi_jayaraman
Active Contributor
0 Kudos

Hi,

You can use <b>submit</b> statement to achieve the same.

Sample Code

REPORT ZREP2 NO STANDARD PAGE HEADING.

tables: qals.

RANGES seltab for qals-prueflos.

WRITE: 'Select a Selection!',

/ '----


'.

SKIP.

FORMAT HOTSPOT COLOR 5 INVERSE ON.

WRITE: 'Selection 1',

/ 'Selection 2'.

AT LINE-SELECTION.

CASE SY-LILLI.

WHEN 4.

SUBMIT zrep1 VIA SELECTION-SCREEN

WITH PARAMET EQ 'Selection 1'

WITH SELECTO IN SELTAB

WITH SELECTO NE 3

AND RETURN.

WHEN 5.

SUBMIT zrep1 VIA SELECTION-SCREEN

WITH PARAMET EQ 'Selection 1'

AND RETURN.

ENDCASE.

Message was edited by: Jayanthi Jayaraman

jayanthi_jayaraman
Active Contributor
0 Kudos

Hi,

You can use <b>submit</b> statement to achieve the same.

SUBMIT rep.

Calls report rep.

The system leaves the active program and starts the new report rep. In basic form 2, you can specify the name of the report in the field name. You must specify the name in uppercase, otherwise a runtime error occurs.

Note

You can only start programs with type '1' using SUBMIT. If the program has a different type, the system triggers a runtime error.

Message was edited by: Jayanthi Jayaraman

Former Member
0 Kudos

Hi,

Use submit if u have select options in the other program.

Regards,

Sharath.

Former Member
0 Kudos

0 Kudos

I wonder why some you bother to answer the question that have been given the correct answer the first time?