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

skip ABAP output screen

naresh_bammidi
Contributor
0 Likes
1,399

Dear Experts ,

I am using BDC call transaction method for 'SP01' tcode . when i execute my Zprogram its showing all spool requests.

up to now fine.but what my problem is ,when i click on back button it's showing ABAP out put screen .my requirement is to come sap initial screen.i tried following code

IF SY-LSIND EQ 1.

LEAVE PROGRAM.

ENDIF.

but its not working.please help me out.

Thanks and regards

Naresh Bammidi

Dear Experts ,

I am using BDC call transaction method for 'SP01' tcode . when i execute my Zprogram its showing all spool requests.

up to now fine.but what my problem is ,when i click on back button it's showing ABAP out put screen .my requirement is to come sap initial screen.i tried following code

IF SY-LSIND EQ 1.

LEAVE PROGRAM.

ENDIF.

but its not working.please help me out.

Thanks and regards

Naresh Bammidi

8 REPLIES 8
Read only

koolspy_ultimate
Active Contributor
0 Likes
1,234

HI,

in your BDC Code after using call transaction i.e


call transaction 'XXXX' using bdcdata mode 'E' update 'S'.

just write leave to screen 1000.

i.e


call transaction 'XXXX' using bdcdata mode 'E' update 'S'.
Leave to screen 1000.

Here after execution you will be redirected to SAP EASY ACCESS Screen.

Regards,

koolspy.

Read only

0 Likes
1,234

Hi koolspy,

Thanks for your quick reply.if i execute my Zprogrm it will show selection screen.here i do enter some values and pass to my transaction.now in pool request screen if i click back button first it should come to my selection-screen then to SAP initial screen( i forgot to add this point in my question ) .How to do.?

Thanks and regards

Naresh Bammidi

Read only

0 Likes
1,234

Hi Try like this, instead of leav program, just call your program..

IF SY-LSIND EQ 1.
SUBMIT ZXXXXXX 
AND RETURN.
*LEAVE PROGRAM.
ENDIF.

Read only

0 Likes
1,234

Hi Naresh,

You need to first set the current screen to 0 as follows.

SET SCREEN 0.

Then you can use LEAVE TO SCREEN 0.

IF SY-LSIND EQ 1.

LEAVE TO SCREEN 0.

ENDIF.

I hope this will resolve your issue.

Regards,

Rahul Mahajan

Read only

0 Likes
1,234

Hi Try like this, instead of leav program, just call your program..

>

>

IF SY-LSIND EQ 1.
> SUBMIT ZXXXXXX 
> AND RETURN.
> *LEAVE PROGRAM.
> ENDIF.

Hi ,

if i use above code it's coming to the initial screen of my Tcode SP01 but not to selection screen.any other idea.

thanks and regards

Naresh bammidi

Read only

0 Likes
1,234

Hi naresh

I think You must have to define PF Status And declare function code for 'BACK' Button.

Use CASE Sy-ucomm .

When 'BACK'.

Call Selection-Screen 1000.

Regards

Ajit

Read only

0 Likes
1,234

Hi Naresh,

>

> You need to first set the current screen to 0 as follows.

>

> SET SCREEN 0.

>

> Then you can use LEAVE TO SCREEN 0.

>

> IF SY-LSIND EQ 1.

> LEAVE TO SCREEN 0.

> ENDIF.

>

> I hope this will resolve your issue.

>

> Regards,

> Rahul Mahajan

Hi rahul ,

does "SET-SCREEN" works for report program ?if so where to write this sttement.?

Thanks and regards

Naresh

Read only

Former Member
0 Likes
1,234

hi naresh ,

try LEAVE TO SCREEN 0.

or

CALL SELECTION-SCREEN 1000 STARTING AT 10 10.

regards

ranjan