System field sy-abcde and tip to get selection screen copy using FM RS_COVERPAGE_SELECTIONS

2
107

1) Often we have requirement to check if a field has only alphabets in it. There are ‘n’ number of ways to do it but the most convenient method is to use system field SY-ABCDE. It is a constant and contains alphabets A, B, C … Z. (i.e A to Z).

[adToAppearHere]

2) At times, business users need to see/print the input parameters of the selection screen along with the output report. To get the copy of the selection screen, we can use standard function module ‘RS_COVERPAGE_SELECTIONS’

Sample code:

* Table For the Selection Screen Report
DATA:
BEGIN OF i_infotable OCCURS 0,
flag(1) TYPE c,
olength TYPE x,
line LIKE rsvar-infoline,
END OF i_infotable.

* Get selection screen copy
CALL FUNCTION ‘RS_COVERPAGE_SELECTIONS’
EXPORTING
report = sy-repid
variant = ”
no_import = ‘X’
TABLES
infotab = i_infotable
EXCEPTIONS
error_message = 1
variant_not_found = 2
OTHERS = 3.

LOOP AT i_infotable.
WRITE:/ i_infotable-line.
ENDLOOP.

Sample Selection Screen:

Sample Copy of the Selection Screen:
Whatever the user entered in the selection screen is captured below.

If you want to get such practical issues and resolutions straight to your inbox, please SUBSCRIBE. We respect your privacy and take protecting it seriously.

If you liked this post, please hit the share button at the left side of your screen.

Thank you very much for your time!!
Image source : www.deathandtaxesmag.com


2 COMMENTS

  1. Wow, that’s what I was seeking for, what a material! existing here at this weblog, thanks admmin of this site.

  2. This post has a lot of importance to the people, I want to do SAP Online Training so please suggest me best training center in USA.

LEAVE A REPLY

Please enter your comment!
Please enter your name here