Application Development and Automation 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: 
Read only

Report Execution in background at user command.

Former Member
0 Likes
1,624

Hi,

I want my program to run in background when the user selects a checkbox to run the program in background. can you please tell how to execute the program in background?

regards,

ravi.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,053

Use:

Function Module:

JOB_OPEN

JOB_CLOSE

JOB_SCHEDULE

[Sample Codes|;

Regards,

Gurpreet

6 REPLIES 6
Read only

viquar_iqbal
Active Contributor
0 Likes
1,053

Hi

To execute a program in background go to se38

Read only

0 Likes
1,053

I want to execute my report in background when the user checks a checkbox in selection screen and pressing execute(F8).Not directly by F9 option in selection screen.

Read only

0 Likes
1,053

Hi

then you need to create a BDC program

when w_check eq 'X'.

perform BDC using progname .

the BDC program should run in the background mode as well so user will not see the screens

you can use session method as well to run the program in background

use w_check eq 'X' AT selection-screen output.

so you will not have to press F8 to make it work

As gurpreet said you can also use job_schedule FM to schedule it in background

Read only

Former Member
0 Likes
1,054

Use:

Function Module:

JOB_OPEN

JOB_CLOSE

JOB_SCHEDULE

[Sample Codes|;

Regards,

Gurpreet

Read only

vinod_vemuru2
Active Contributor
0 Likes
1,053

Hi Ravi,

Follow below logic.

If check box is selected

AND sy-batch IS INITIAL. "Means currently u r running report in foreground

CALL FUNCTION JOB_OPEN.

SUBMIT ur program using SUBMIT statement.

CALL FUNCTION JOB_CLOSE.

ELSE.

Normal processing.

ENDIF.

Thanks,

Vinod.

Read only

0 Likes
1,053

Thanks you for recollectiog me of the Job scheduling.