on 10-14-2004 9:02 PM
Hi,
I want to create a common include or a function module to write the Selection Screen Input values in each report I write(at the end of the report as the last page).
I want to pass just the Program name (SY-CPROG) to the fn module or include. The fn module may use LOAD statement.
Is there someone who has already done this before?
Thanks,
Bala
Hi,
Function module RS_LIST_SELECTION_TABLE could provide you with the info you need.
Cheers
Colin
PS. If this fixes your issue, please award me the points as so few people do !
Thanks.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Bala,
If you were to do something like this, then you'd get your desired result:
<b> DATA : PRGNAME LIKE SY-REPID.
DATA: BEGIN OF ITAB_VAR OCCURS 0.
INCLUDE STRUCTURE RSPARAMS.
DATA: END OF ITAB_VAR.
PRGNAME = SY-REPID.
CALL FUNCTION 'RS_LIST_SELECTION_TABLE'
EXPORTING
REPORT = PRGNAME
NEWPAGE = ' '
SELTEXT = 'X'
TABLES
SEL_TAB = ITAB_VAR.</b>
I hope this helps.
Hafeez
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Yes, it is possible. I have done that before.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Bala,
Take a look at this piece of code to see how it works:
FORM print_selections.
DATA:
zzl_repid TYPE syst-repid,
zt_selections TYPE TABLE OF rsparams.
zzl_repid = syst-repid.
CALL FUNCTION 'RS_REFRESH_FROM_SELECTOPTIONS'
EXPORTING
curr_report = zzl_repid
TABLES
selection_table = zt_selections
EXCEPTIONS
OTHERS = 0.
CALL FUNCTION 'RS_LIST_SELECTION_TABLE'
EXPORTING
report = zzl_repid
seltext = 'X'
newpage = ' '
TABLES
sel_tab = zt_selections
EXCEPTIONS
OTHERS = 0.
SKIP 3.
ENDFORM. " print_selections
If this helps, please give your points to Colin, as he provided the solution already.
Regards,
John.
User | Count |
---|---|
93 | |
10 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.