‎2009 Sep 22 7:32 AM
Hi all,
I am developing a report in which there is a selection screen containing 2 list boxes having month 'from' and 'to' ;ie the month range for which the report is to be run and a parameter for year.below it i have 2 radio button options which will lead to the report that the user clicks on.
I have done the following in the code.
selection-screen begin of block b1 with frame title text-001.
parameters: month1(10) as listbox visible length 10 obligatory.
parameters: month2(10) as listbox visible length 10.
parameters: year(4) obligatory.
selection-screen : end of block b1.
selection-screen: begin of block b2 with frame title text-002.
parameters: rb1 radiobutton group g1,
rb2 radiobutton group g1.
selection-screen : end of block b2.
if rb1 = 'X'.
submit ZMIS1.
ENDIF.
if rb2 = 'X'.
submit ZMIS2.
endif.
Now i want the values selected in the listbox and the year to be passed in the report that will be selected in the radiobutton (ie ZMIS1 or ZMIS2) so that the corresponding report output will be displayed directly with the inputs given in the selection screen .
Please tell me how to do this.Thanks in advance.
‎2009 Sep 22 7:38 AM
HI,
Use Memory ID's.
The EXPORT TO MEMORY and IMPORT FROM MEMORY statements allow you to write data to, or read data from, the ABAP memory.
Swathi
‎2009 Sep 22 7:45 AM
Hi,
<li>Use USER COMMAND addition to your parameter statement for the radiobuttons.
<li>Check this w
Thanks
Venkat.OSELECTION-SCREEN: BEGIN OF BLOCK B2 WITH FRAME TITLE TEXT-002.
PARAMETERS: RB1 RADIOBUTTON GROUP G1 USER-COMMAND uc1, "USER_COMMAND
RB2 RADIOBUTTON GROUP G1.
SELECTION-SCREEN : END OF BLOCK B2.
‎2009 Sep 22 7:51 AM
You also have to pass Selection-screen data for called program the way it has been shown down.
Thanks
Venkat.O
REPORT ZVENKAT_ALV_LIST.
DATA:
IT_RSPARAMS TYPE STANDARD TABLE OF RSPARAMS,
WA_RSPARAMS LIKE LINE OF IT_RSPARAMS.
SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.
PARAMETERS: MONTH1(10) AS LISTBOX VISIBLE LENGTH 10 OBLIGATORY.
PARAMETERS: MONTH2(10) AS LISTBOX VISIBLE LENGTH 10.
PARAMETERS: YEAR(4) OBLIGATORY.
SELECTION-SCREEN : END OF BLOCK B1.
SELECTION-SCREEN: BEGIN OF BLOCK B2 WITH FRAME TITLE TEXT-002.
PARAMETERS: RB1 RADIOBUTTON GROUP G1 USER-COMMAND UC1,
RB2 RADIOBUTTON GROUP G1.
SELECTION-SCREEN : END OF BLOCK B2.
IF RB1 = 'X'.
WA_RSPARAMS-SELNAME = 'P_MATNR'. "PARAMETER or SELECT-OPTION of the called program
WA_RSPARAMS-KIND = 'P'. "S=Select-options P=Parameters
WA_RSPARAMS-SIGN = 'I'.
WA_RSPARAMS-OPTION = 'EQ'.
WA_RSPARAMS-LOW = '11010'.
WA_RSPARAMS-HIGH = SPACE.
SUBMIT ZMIS1 WITH SELECTION-TABLE RSPARAMS AND RETURN.
ENDIF.
IF RB2 = 'X'.
WA_RSPARAMS-SELNAME = 'P_MATNR'. "PARAMETER or SELECT-OPTION of the called program
WA_RSPARAMS-KIND = 'P'. "S=Select-options P=Parameters
WA_RSPARAMS-SIGN = 'I'.
WA_RSPARAMS-OPTION = 'EQ'.
WA_RSPARAMS-LOW = '11010'.
WA_RSPARAMS-HIGH = SPACE.
SUBMIT ZMIS2 WITH SELECTION-TABLE RSPARAMS AND RETURN.
ENDIF.
‎2009 Sep 22 9:42 AM
Thanks for the sujjestion. plz tell me what modifications have to be made in the ZMIS1 and ZMIS2 reports ie the reports that i am calling using SUBMIT command.At present those report contains the selection screen declarations also apart from the main logic of the report.Secondly;what is the use of the 'USER-COMMAND uc1' command in the radio button declaration?
Here is a small part of the code.
report zmis1 line-size 185 no standard page heading.
type-pools : vrm.
data: param type vrm_id,
values type vrm_values,
values1 type vrm_values,
value like line of values,
value1 like line of values.
selection-screen begin of block b1 with frame title text-001.
parameters: month1(10) no-display .
parameters: month2(10) no-display.
parameters: fiscal(4) no-display.
selection-screen : end of block b1.
AFTER THIS IT CONTAINS THE REPORT LOGIC.
‎2009 Sep 22 12:43 PM
Thanks for the sujjestion. plz tell me what modifications have to be made in the ZMIS1 and ZMIS2 reports ie the reports that i am calling using SUBMIT command.At present those report contains the selection screen declarations also apart from the main logic of the report.Secondly;what is the use of the 'USER-COMMAND uc1' command in the radio button declaration?
Here is a small part of the code.
report zmis1 line-size 185 no standard page heading.
type-pools : vrm.
data: param type vrm_id,
values type vrm_values,
values1 type vrm_values,
value like line of values,
value1 like line of values.
selection-screen begin of block b1 with frame title text-001.
parameters: month1(10) no-display .
parameters: month2(10) no-display.
parameters: fiscal(4) no-display.
selection-screen : end of block b1.
AFTER THIS IT CONTAINS THE REPORT LOGIC.