10-11-2006 6:46 PM
Hi all,
I have an issue with message.
in my program i am giving a message statment as
Message I000(0) with ' message'.
this error message pops us when ever there is no data in the database.
this i am checking in my selection screen.
once this message pops up , i want to stay on the same selection-screen with out executing the code.
Can anyone let me know the solution.
Regards,
Roby
10-11-2006 6:59 PM
10-11-2006 6:50 PM
10-11-2006 6:55 PM
Hi rich.
i dont have my code in at selection-screen.
i have it inside Start-of-selection.
will STOP work for that as well. Let me know
Regards,
Roby.
10-11-2006 6:57 PM
Hi,
Use leave-list processing.
START-OF-SELECTION.
Do the validations.
MESSAGE I001.
LEAVE LIST-PROCESSING.
Thanks,
Naren
10-11-2006 6:59 PM
10-11-2006 10:41 PM
Hi Rich,
I did use stop statment.
but the problem when i am executing it as a report i am not getting an error.
but when i am executing this report attached to a Transaction code . i am getting error.
the error is :
The STOP statement was used outside a report flow.
can you let me know any solution for this .
Regards,
Roby
10-12-2006 12:12 AM
10-12-2006 12:22 AM
It is submitted through Submit , it creates a session .
it is an se38 program attached to a tcode .
if i use leave program will it stay at the selection-screen.
Let me know .
Regards,
Roby
10-12-2006 12:25 AM
10-12-2006 12:49 AM
Hi Rich,
I submitting a ZREPORT through tcode ZREPORT1.
when i execute the TCODE.
i will be getting a Selection-Screen i am entering values in it .
based on the values .
i am executing this code .
SELECT SINGLE * FROM table.
IF SY-SUBRC <> 0.
MESSAGE I000(0) WITH ' No Entries Exists in Database '.
LEAVE TO SCREEN xyz.
ENDIF.
ENDIF.
( if sy-subrc fails ) . i am poping up a message. if i use leave program it comes out of the program.
my requirement is after it issues a message it shouls stay on the selection screen itself .
if the execute the report through se38 and put stop after the message it stays in the selection screen.
if i execute the report through tcode , it gives a dump.
Please do let me know what the issue is .
Regards,
Roby.
10-12-2006 12:53 AM
I believe you may have create the tcode wrong. Delete the tcode and recreate. This time choose the radiobutton for "Program with selection screen(report transaction)".
Use the STOP statement or the LEAVE LIST-PROCESSING statement in your program. It should work fine then.
IF SY-SUBRC <> 0.
MESSAGE I000(0) WITH ' No Entries Exists in Database '.
<b>STOP.</b>
ENDIF.
Regards,
Rich Heilman
10-12-2006 1:02 AM
Hi Rich & Narendran ,
It solved my problem , but i am trying to award points it is giving me an error message, let me know how to rectify this error so that i can award the points.
Regards,
Roby
10-12-2006 1:11 AM
10-12-2006 12:13 AM
Hi,
Use leave-list processing.
START-OF-SELECTION.
Do the validations.
MESSAGE I001.
LEAVE LIST-PROCESSING.
Thanks,
Naren
10-12-2006 12:20 AM
Hi Narendran,
I have attached this program to a TCODE . i have tried your option it is not working .
Can you let me know any other option.
Regards,
Roby
10-12-2006 12:23 AM
10-12-2006 12:26 AM
Hi,
You are trying to submit a program let's say 'ZREPORT' from a report ZREPORT_CALLING..
When you are submitting the report it should stay in the selection-screen of ZREPORT if there is any error in the report ZREPORT..
Is this your requirement??
Thanks,
Naren
10-12-2006 12:49 AM
Hi Narendran,
I submitting a ZREPORT through tcode ZREPORT1.
when i execute the TCODE.
i will be getting a Selection-Screen i am entering values in it .
based on the values .
i am executing this code .
SELECT SINGLE * FROM table.
IF SY-SUBRC <> 0.
MESSAGE I000(0) WITH ' No Entries Exists in Database '.
LEAVE TO SCREEN xyz.
ENDIF.
ENDIF.
( if sy-subrc fails ) . i am poping up a message. if i use leave program it comes out of the program.
my requirement is after it issues a message it shouls stay on the selection screen itself .
if the execute the report through se38 and put stop after the message it stays in the selection screen.
if i execute the report through tcode , it gives a dump.
Please do let me know what the issue is .
Regards,
Roby.