‎2007 Mar 22 11:52 AM
Hi all,
I am facing problem in calling a program from another program.
Actually i have two reports Report1 and Report2.
In Report1 there is a data in internal tables.Now i want to execute report2 from report1 just by filling the report2 selection screen with the data present in the internal tables.that means when i execute the report1 it will display the output of the report two by taking the data present in the internal tables of the report1 into its selection screen.
Thanks in advance
‎2007 Mar 22 11:54 AM
Hi Shwetha,
Use the SUBMIT keyword and call the first program into the second program.
Hope this resolves your query.
Reward all the helpful answers.
Regards
‎2007 Mar 22 11:54 AM
Hi Shwetha,
Use the SUBMIT keyword and call the first program into the second program.
Hope this resolves your query.
Reward all the helpful answers.
Regards
‎2007 Mar 22 11:56 AM
Hi
REPORT ZREPORT1.
EXPORT ITAB TO MEMORY ID 'ZREPORT1'.
SUBMIT ZREPORT2 WITH ..................... AND RETURN.
REPORT ZREPORT2.
INITIALIZATION.
IMPORT ITAB FROM MEMORY ID 'ZREPORT1'.
Max
‎2007 Mar 22 11:58 AM
HI,
see this example.
program1.
REPORT ZEXAMPLE10.
tables:mara.
select-options:matnr for mara-matnr.
submit zexample11 with i_matnr in matnr and return.
program2.
REPORT ZEXAMPLE11.
tables:mara.
select-options:i_matnr for mara-matnr.
select * from mara where matnr in i_matnr.
write:/ mara-matnr.
endselect.
check this code this will b helpful.
regards,
bharat.
‎2007 Mar 22 11:58 AM
Hi..
use Submit <prg name> via Selection screen.
hope this helps..
-kothai
‎2007 Mar 22 11:59 AM
Hi Shweta,
When ever you want a program to be called from another program just use SUBMIT <Program Name>, then it will execute that program and then it then comes to the current program.
Thanks and regards
Vipin Das
‎2007 Mar 22 1:03 PM
Hi!
In the first Report program, write
SUBMIT REPORT2 WITH ..................... AND RETURN.
This statement calls REPORT2 executes it and control returns back to REPORT1.
Reward if it helps.
Regards,
Neha Bansal.