07-13-2006 7:26 AM
Hi All,
I have a issue in regard to displaying messages in the Selection-Screen.
Actually i will fetch all my data in START-OF_SELECTION.
At the end of START-OF_SELECTION logic only i will be able to know my main internal table will have data for the report output (or) not.
So in END-OF-SELECTION i have to give a message to the user if my main internal table does not contain any data.
That message should come at the bottom of selection-screen like 'No Data Found' and message should stay on selection-screen and then user will again input the data.
It is not giving message E/W in AT SELECTION-SCREEN i need to give E/W error message in END-OF-SELECTION and that message should stay on selection-screen it should not take me to Blank screen and display error message.
Can anybody give the solution for the same.
Thanks in advance.
Thanks & Regards,
Prasad.
07-13-2006 7:30 AM
Hello,
Use
MEssage s001 with .....
leave list-processing.
instead of
Message E001
Regards,
Naimesh
07-13-2006 7:30 AM
Hello,
Use
MEssage s001 with .....
leave list-processing.
instead of
Message E001
Regards,
Naimesh
07-13-2006 7:32 AM
Hi,
Give message like :
message s000(xxx) with ' No data Found'. if you gave an error message, blank screen will appear.
Regards
Appana
07-13-2006 7:40 AM
hi,
try:
describe table itab lines sy-tfill.
if sy-tfill = 0.
message s001(00) with 'no data found!'.
exit.
endif.
A.
07-13-2006 7:37 AM
Hi,
You can do it in START_OF_SELECTION only.
eg.
START-OF-SELECTION.
SELECT....
IF SY-SUBRC NE 0.
MESSAGE s000(00) with text..
<b>STOP.</b>
ENDIF.
It will remain on the Selection Screen.
Regards,
Shashank
07-13-2006 7:37 AM
Hi,
For this issue you can try this option.
In end of selection check the internal table ( ex ITAB ).
end-of-selection.
If ITAB[] is initial.
Message S(message number ) display like 'E'
leave list-processing.
endif.
If you use the above code then you will get the error message in the status bar of the selection screen itself.
Thanks & Regards,
Rajanidhi Rajasekeran