Regarding modify selection-screen
sorry but this funda has never been clear to me
can you please help me out
on my selection screen i have 3 fields
1 employee
2. start date
3. end date
and two radio buttons
1. employee wise report
2.detailed report
now when i select the employee wise report then it should display the employee field on the selection screen
and if i select the detailed report radio button then the selection screen should have only two fields that is start and end date
tere should be no employee field on the selection screen then
i have given a screen modif id sc1 to to the employee
and tried one or two ways but no use
can anyone please help me out.
hi check this code
this code actually removes the block data when check box is checked and shows the block on deselecting it.U can change the chk box condition according to ur requirement.
SELECTION-SCREEN BEGIN OF BLOCK FPATH .
SELECTION-SCREEN : BEGIN OF LINE .
PARAMETERS : p_EU AS CHECKBOX USER-COMMAND CHK MODIF ID BL1.
SELECTION-SCREEN : COMMENT 4(15) TEXT-106 FOR FIELD P_EU.
SELECTION-SCREEN : END OF LINE .
SELECTION-SCREEN : BEGIN OF LINE.
PARAMETERS : P_LOCL AS CHECKBOX MODIF ID BL1.
SELECTION-SCREEN : COMMENT 4(15) TEXT-002 FOR FIELD P_LOCL.
SELECTION-SCREEN POSITION 33.
PARAMETER: P_FILE1 LIKE RLGRAP-FILENAME MODIF ID BL1.
SELECTION-SCREEN : END OF LINE .
SELECTION-SCREEN : BEGIN OF LINE .
PARAMETERS: P_APPL AS CHECKBOX DEFAULT 'X' MODIF ID BL1.
SELECTION-SCREEN : COMMENT 4(13) TEXT-003 FOR FIELD P_APPL.
SELECTION-SCREEN POSITION 33.
PARAMETER: FNAM2 LIKE RLGRAP-FILENAME MODIF ID BL1.
SELECTION-SCREEN : END OF LINE .
SELECTION-SCREEN END OF BLOCK FPATH.
SELECTION-SCREEN BEGIN OF BLOCK FPATH1 .
SELECTION-SCREEN : BEGIN OF LINE .
PARAMETERS : p_APAC AS CHECKBOX MODIF ID BL2 USER-COMMAND CH.
SELECTION-SCREEN : COMMENT 4(15) TEXT-105 FOR FIELD P_APAC.
SELECTION-SCREEN : END OF LINE .
SELECTION-SCREEN : BEGIN OF LINE.
PARAMETERS : P_LOCL1 AS CHECKBOX MODIF ID BL2.
SELECTION-SCREEN : COMMENT 4(15) TEXT-102 FOR FIELD P_LOCL1.
SELECTION-SCREEN POSITION 33.
PARAMETER: P_FILE11 LIKE RLGRAP-FILENAME MODIF ID BL2.
SELECTION-SCREEN : END OF LINE .
SELECTION-SCREEN : BEGIN OF LINE .
PARAMETERS: P_APPL1 AS CHECKBOX DEFAULT 'X' MODIF ID BL2.
SELECTION-SCREEN : COMMENT 4(13) TEXT-103 FOR FIELD P_APPL1.
SELECTION-SCREEN POSITION 33.
PARAMETER: FNAM21 LIKE RLGRAP-FILENAME MODIF ID BL2.
SELECTION-SCREEN : END OF LINE .
SELECTION-SCREEN END OF BLOCK FPATH1.
AT SELECTION-SCREEN OUTPUT.
LOOP AT SCREEN.
IF P_EU = 'X' AND SCREEN-GROUP1 = 'BL2'.
SCREEN-ACTIVE = 0.
ENDIF.
IF P_APAC = 'X' AND SCREEN-GROUP1 = 'BL1'.
SCREEN-ACTIVE = 0.
ENDIF.
MODIFY SCREEN.
ENDLOOP.
Similar Messages
-
hi friends,
I am trying to modify selection-screen.
I want select-option to get disabled when i check one checkbox.I am using SCREEN table for this purpose.
But on selection-screen when i check checkbox select-option is not getting disabled at that time . it happens only when i press ENTER.
Plz anybody tell me how can i disable SO only by checking the checkbox.
<REMOVED BY MODERATOR>
SM.
Edited by: Alvaro Tejada Galindo on Mar 18, 2008 6:47 PMTry This,
TABLES:
vbak.
SELECT-OPTIONS:
so_vbeln FOR vbak-vbeln MODIF ID a.
PARAMETERS: p_acta TYPE checkbox USER-COMMAND act DEFAULT 'X'.
AT SELECTION-SCREEN OUTPUT.
LOOP AT SCREEN.
IF p_acta = ' '.
IF screen-group1 = 'A'.
screen-active = 0.
ENDIF.
ENDIF.
MODIFY SCREEN.
ENDLOOP.
Edited by: Rengith Skariah on Mar 18, 2008 1:44 PM
Edited by: Rengith Skariah on Mar 18, 2008 1:46 PM -
Modifying Selection screen dynamically
Hi guyz
herez another question
Can we modify selection-screen dynamically as we do in case of screen
What i want to do is
I want to display one parameter as checkbox and when user ticks this box I want to display another one
If we are defining two checkboxes earlier and making one invisible than can we modify selection screen to display another check box
Thanks in advanceTake a look at this example.
REPORT EVENT_DEMO.
SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME.
PARAMETERS: R1 RADIOBUTTON GROUP RAD1 DEFAULT 'X',
R2 RADIOBUTTON GROUP RAD1,
R3 RADIOBUTTON GROUP RAD1.
SELECTION-SCREEN END OF BLOCK B1.
SELECTION-SCREEN BEGIN OF BLOCK B2 WITH FRAME.
PARAMETERS: R4 RADIOBUTTON GROUP RAD2 DEFAULT 'X',
R5 RADIOBUTTON GROUP RAD2,
R6 RADIOBUTTON GROUP RAD2.
SELECTION-SCREEN END OF BLOCK B2.
AT SELECTION-SCREEN ON RADIOBUTTON GROUP RAD1.
IF R1 = 'X'.
MESSAGE W040(HB).
ENDIF.
AT SELECTION-SCREEN ON RADIOBUTTON GROUP RAD2.
IF R4 = 'X'.
MESSAGE W040(HB).
ENDIF. -
Modifying selection screen with help of radio buttons
Hi,
In my program am using three parameters to download a three different files and I have to use radiobuttons for that.
I want to download only one file at a time.
I have used MODIF ID but it is not working for 3 Parameters but it is working for only two parameters.
Please help me out!!!!!!!!!Hi,
check with the following code
* Parameters and Selection Options
SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.
SELECT-OPTIONS: s_lifnr FOR lfm1-lifnr .
SELECTION-SCREEN END OF BLOCK b1.
SELECTION-SCREEN BEGIN OF BLOCK b2 WITH FRAME TITLE text-002.
PARAMETERS:
r_asn RADIOBUTTON GROUP rad1 USER-COMMAND uc1 DEFAULT 'X',
r_ers RADIOBUTTON GROUP rad1 ,
r_830 RADIOBUTTON GROUP rad1,
r_850 RADIOBUTTON GROUP rad1,
r_862 RADIOBUTTON GROUP rad1,
r_810 RADIOBUTTON GROUP rad1,
r_820 RADIOBUTTON GROUP rad1,
r_824 RADIOBUTTON GROUP rad1.
SELECTION-SCREEN END OF BLOCK b2.
SELECTION-SCREEN BEGIN OF BLOCK b3 WITH FRAME TITLE text-003.
SELECT-OPTIONS: s_bstae FOR lfm1-bstae MODIF ID sd1.
PARAMETERS:
p_ekorg TYPE lfm1-ekorg MODIF ID md1,
p_evcode TYPE edp21-evcode MODIF ID md2,
p_kappl TYPE nach-kappl MODIF ID md3,
p_parvw TYPE nach-parvw MODIF ID md4,
p_kschl TYPE nach-kschl MODIF ID md5,
p_vakey TYPE nach-vakey MODIF ID md6,
p_werks TYPE werks_d MODIF ID md7,
p_bukrs TYPE lfb1-bukrs MODIF ID md8.
SELECTION-SCREEN END OF BLOCK b3.
*eject
* Initialization
INITIALIZATION.
* PERFORM check_authorization.
*eject
* at selection screen
*AT SELECTION-SCREEN.
AT SELECTION-SCREEN OUTPUT.
LOOP AT SCREEN.
IF r_asn EQ 'X'
AND ( screen-group1 = 'MD3' or screen-group1 = 'MD4'
or screen-group1 = 'MD5' or screen-group1 = 'MD6'
or screen-group1 = 'MD7' or screen-group1 = 'MD8').
screen-active = '0'.
screen-invisible = '1'.
screen-input = '0'.
screen-output = '0'.
ELSEIF r_ers EQ 'X'
AND ( screen-group1 = 'SD1' or screen-group1 = 'MD1'
or screen-group1 = 'MD2' or screen-group1 = 'MD3'
or screen-group1 = 'MD4' or screen-group1 = 'MD5'
or screen-group1 = 'MD6' or screen-group1 = 'MD7'
or screen-group1 = 'MD8').
screen-active = '0'.
screen-invisible = '1'.
screen-input = '0'.
screen-output = '0'.
ELSEIF r_830 EQ 'X'
AND ( screen-group1 = 'SD1' or screen-group1 = 'MD1'
or screen-group1 = 'MD2' or screen-group1 = 'MD6'
or screen-group1 = 'MD7' or screen-group1 = 'MD8').
screen-active = '0'.
screen-invisible = '1'.
screen-input = '0'.
screen-output = '0'.
ELSEIF r_850 EQ 'X'
AND ( screen-group1 = 'SD1' or screen-group1 = 'MD1'
or screen-group1 = 'MD2' or screen-group1 = 'MD6'
or screen-group1 = 'MD7' or screen-group1 = 'MD8').
screen-active = '0'.
screen-invisible = '1'.
screen-input = '0'.
screen-output = '0'.
ELSEIF r_862 EQ 'X'
AND ( screen-group1 = 'SD1' or screen-group1 = 'MD1'
or screen-group1 = 'MD2' or screen-group1 = 'MD8').
screen-active = '0'.
screen-invisible = '1'.
screen-input = '0'.
screen-output = '0'.
ELSEIF r_810 EQ 'X'
AND ( screen-group1 = 'MD3' or screen-group1 = 'MD4'
or screen-group1 = 'MD5' or screen-group1 = 'MD6'
or screen-group1 = 'MD7' or screen-group1 = 'MD8').
screen-active = '0'.
screen-invisible = '1'.
screen-input = '0'.
screen-output = '0'.
ELSEIF r_820 EQ 'X'
AND ( screen-group1 = 'SD1' or screen-group1 = 'MD1'
or screen-group1 = 'MD2' or screen-group1 = 'MD3'
or screen-group1 = 'MD4' or screen-group1 = 'MD5'
or screen-group1 = 'MD6' or screen-group1 = 'MD7' ).
screen-active = '0'.
screen-invisible = '1'.
screen-input = '0'.
screen-output = '0'.
ELSEIF r_824 EQ 'X'
AND ( screen-group1 = 'SD1' or screen-group1 = 'MD1'
or screen-group1 = 'MD2' or screen-group1 = 'MD3'
or screen-group1 = 'MD4' or screen-group1 = 'MD5'
or screen-group1 = 'MD6' or screen-group1 = 'MD7'
or screen-group1 = 'MD8').
screen-active = '0'.
screen-invisible = '1'.
screen-input = '0'.
screen-output = '0'.
ENDIF.
MODIFY SCREEN.
ENDLOOP.
*eject
* Event top of page
TOP-OF-PAGE.
*eject
* event Start of Selection
START-OF-SELECTION.
*eject
*EVENT End-of selection
END-OF-SELECTION.
*eject
*EVENT End-of page
END-OF-PAGE.
Regards,
Vikas.
plz reward if helpful.. -
Hi Experts,
In the selection-screen, i have 2 radiobuttons .
parameters : rb1 radiobutton group g2 ,
rb2 radiobutton group g2 .
and 4 input fields.
SELECT-OPTIONS : S_MATNR FOR MARA-MATNR. " OBLIGATORY.
SELECT-OPTIONS : S_MTART FOR MARA-MTART NO INTERVALS NO-EXTENSION.
SELECT-OPTIONS : S_WERKS FOR MARA-MATNR NO INTERVALS NO-EXTENSION.
parameters : lifnr like lfa1-lifnr .
Now my requirement is when i execute the report by default the 1st radiobutton is selected. For this radiobutton,
i want to display only the first 3 select-options. And when the user clicks on the second radiobutton,
the parameter LIFNR should appear without pressing enter button. Again when the user clicks on
1st radiobutton the parameter field LIFNr should not appear.
Please can anybod yrpovide the code.
Thanks in advance.Hi,
Test the Code Bellow it is working as per your requirement,
TABLES: mara.
PARAMETERS : rb1 RADIOBUTTON GROUP g2 USER-COMMAND a DEFAULT 'X',
rb2 RADIOBUTTON GROUP g2 .
SELECTION-SCREEN BEGIN OF BLOCK a WITH FRAME TITLE text-001.
SELECT-OPTIONS : s_matnr FOR mara-matnr MODIF ID s1. " OBLIGATORY.
SELECT-OPTIONS : s_mtart FOR mara-mtart NO INTERVALS NO-EXTENSION MODIF ID s1.
SELECT-OPTIONS : s_werks FOR mara-matnr NO INTERVALS NO-EXTENSION MODIF ID s1.
SELECTION-SCREEN END OF BLOCK a.
SELECTION-SCREEN BEGIN OF BLOCK b WITH FRAME TITLE text-002.
PARAMETERS : lifnr LIKE lfa1-lifnr MODIF ID s2.
SELECTION-SCREEN END OF BLOCK b.
BREAK-POINT.
AT SELECTION-SCREEN OUTPUT.
IF rb1 = 'X'.
LOOP AT SCREEN.
IF screen-group1 = 'S2'.
screen-active = 0.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ELSEIF rb2 = 'X'.
LOOP AT SCREEN.
IF screen-group1 = 'S1'.
screen-active = 0.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ENDIF.
Best Regards,
Faisal -
Regarding At Selection-Screen On field
Hi..
When we wil use At Selection-Screen On <Field>
and At Selection-Screen On Radiobutton.
What is the purpose of these events.
I need samplecode for these events.
Regards
Sandeep.Hi Sandeep
hope this will help you.
REPORT zextest595 .
*--- Radiobuttons
PARAMETERS: p_up RADIOBUTTON GROUP a DEFAULT 'X' USER-COMMAND rb,
p_list RADIOBUTTON GROUP a.
PARAMETERS: p_pcfile LIKE rlgrap-filename OBLIGATORY DEFAULT 'C:\'
MODIF ID ccc,
p_pctype LIKE rlgrap-filetype OBLIGATORY DEFAULT 'ASC'
MODIF ID ccc,
p_unix LIKE rlgrap-filename OBLIGATORY DEFAULT '.\'
MODIF ID ccc.
PARAMETERS: p_dir LIKE rlgrap-filename OBLIGATORY DEFAULT '.'
MODIF ID ddd,
p_fp LIKE rlgrap-filename
MODIF ID ddd.
AT SELECTION-SCREEN
AT SELECTION-SCREEN OUTPUT.
IF p_up = 'X' .
LOOP AT SCREEN.
CASE screen-group1.
WHEN 'CCC'.
screen-input = 1. "Enable
screen-invisible = 0. "Disable
MODIFY SCREEN.
WHEN 'DDD'.
screen-input = 0.
screen-invisible = 1.
MODIFY SCREEN.
ENDCASE.
ENDLOOP.
ENDIF.
IF p_list = 'X'.
LOOP AT SCREEN.
CASE screen-group1.
WHEN 'CCC'.
screen-input = 0.
screen-invisible = 1.
MODIFY SCREEN.
WHEN 'DDD'.
screen-input = 1.
screen-invisible = 0.
MODIFY SCREEN.
ENDCASE.
ENDLOOP.
ENDIF. -
Regarding Hardcoding selection-screen field.
Hi frnds,
I want to hardcode vbak-erdat in my selection screen , i m using loop at screen . and i m also usiing INITIALIZATION EVENT,where i am initializing vbak-erdat.
so frnds can anyone help me in this regard.
Thanks,
satishHi,
Please look at the code below :
TABLES : bsis.
SELECTION-SCREEN : BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.
PARAMETER : sp_sel radiobutton group rad USER-COMMAND radio DEFAULT 'X',
sp_all RADIOBUTTON GROUP rad.
SELECTION-SCREEN END OF BLOCK b1.
SELECTION-SCREEN BEGIN OF BLOCK b2 WITH FRAME TITLE text-002.
SELECT-OPTIONS : so_bukrs FOR bsis-bukrs MODIF ID sp1.
SELECT-OPTIONS : so_hkont FOR bsis-hkont MODIF ID sp2.
SELECTION-SCREEN END OF BLOCK b2.
AT SELECTION-SCREEN OUTPUT.
LOOP AT SCREEN.
IF sp_sel = 'X'.
IF screen-group1 = 'SP2'.
screen-input = '0'.
screen-invisible = '0'.
screen-required = '0'.
MODIFY SCREEN.
ENDIF.
elseif sp_all = 'X'.
IF screen-group1 = 'SP1'.
screen-input = '0'.
screen-invisible = '0'.
screen-required = '0'.
MODIFY SCREEN.
ENDIF.
endif.
ENDLOOP.
Thanks,
Sriram Ponna. -
Regarding hiding Selection screen block
hi all ,
i have 2 blocks in the selection screen. the First block has 4 radiobuttons and the second block has 4 parameters.
i need to hide the block 2 based on the radiobutton checked in the initail block.
if radiobutton 1 or 2 is selected then the block should not be visible and if the rdbtn 3 or 4 is selected the block should be visible
i have wriiten the code but it doesn't work at all. the block is hidden but when i select the radiobtn 3 or 4 it doesn't work
the code i hve wriiten is as follows
SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.
PARAMETERS: par1 RADIOBUTTON GROUP rg2 DEFAULT 'X' USER-COMMAND ucom1
PARAMETERS: par2 RADIOBUTTON GROUP rg2 .
PARAMETERS: par3 RADIOBUTTON GROUP rg2 .
PARAMETERS: par4 RADIOBUTTON GROUP rg2
SELECTION-SCREEN END OF BLOCK b1.
SELECTION-SCREEN BEGIN OF BLOCK a1 WITH FRAME TITLE text-001.
SELECTION-SCREEN BEGIN OF LINE.
PARAMETER p_pwwrk TYPE plaf-pwwrk MODIF ID FSC.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
PARAMETERS p_wch TYPE cr_hname MODIF ID FSC.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
SELECT-OPTIONS s_mdv01 FOR g_mdv01 MODIF ID FSC.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN END OF BLOCK a1.
I have declared this after Initialization.
AT SELECTION-SCREEN OUTPUT.
if par3 eq 'X' or par4 eq 'X'.
LOOP AT SCREEN.
IF screen-group1 = 'FSC'.
screen-active = 0.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
endif.
can anybody please suggest.
Thanx
SrinivasHiding Input Fields Locate the document in its SAP Library structure
To suppress the display of the input field on the selection screen, you use the following syntax:
PARAMETERS p ...... NO-DISPLAY ......
Although parameter p is declared, it is not displayed on the selection screen.
If the parameter belongs to the standard selection screen, you can assign a value to it either by using the DEFAULT addition when you declare it, or during the INITIALIZATION event. If you call the executable program using the SUBMIT statement, the calling program can also pass the value.
When you use user-defined selection screens, you can assign a value to the parameter at any time before calling the selection screen.
If you want to display a parameter only in certain cases, for example, depending on the values entered by the user in other input fields of the selection screen, you cannot use the NO-DISPLAY addition. If you use NO-DISPLAY, the parameter actually is an element of the interface for program calls, but not an element of the selection screen. As a result, you cannot make it visible using the MODIFY SCREEN statement.
To hide a parameter that is an element of the selection screen, you must declare it without the NO-DISPLAY addition and suppress its display using the MODIFY SCREEN statement.
We can Hide parameter / select option in selection screen dynamically by manipulating screen object.
SCREEN is like an internal table with a header line. However, you do not have to declare it in your program. Go to debugging mode and then view structure of screen.
You can modify SCREEN in your ABAP program during the PBO event of a screen. Its contents override the static attributes of the screen fields for a single screen call. The only statements that you can use with SCREEN are:
LOOP AT SCREEN.
MODIFY SCREEN.
ENDLOOP.
We can hide parameter by set screen-active to 0.
Here is example of how to hide parameter in selection screen. Write it, and change click on radiobutton to hide parameter.
REPORT ZAALGAL0006.
DATA: d_ucomm LIKE sy-ucomm.
PARAMETERS: p_grpa1(10) MODIF ID A,
p_grpa2(5) MODIF ID A,
p_grpb1(2) MODIF ID B.
PARAMETERS: p_actA RADIOBUTTON GROUP rad1 USER-COMMAND ACT DEFAULT 'X',
p_actB RADIOBUTTON GROUP rad1.
AT SELECTION-SCREEN.
d_ucomm = sy-ucomm.
AT SELECTION-SCREEN OUTPUT.
LOOP AT screen.
IF p_actA = 'X'.
IF screen-group1 = 'B'.
screen-active = 0.
ENDIF.
ELSEIF p_actB = 'X'.
IF screen-group1 = 'A'.
screen-active = 0.
ENDIF.
ENDIF.
MODIFY screen.
ENDLOOP.
START-OF-SELECTION.
regards,
srinivas
<b>*reward for useful answers*</b> -
Regarding at selection screen event
hi experts,
i m working on hr abap report with the help of pnp ldb i made my selection screen using report category 'PY_DEF' now what i want that i m not using the first selction screen which contains current period details etc but when i click on the payroll period button the second selection screen is coming no doubt... containing payroll area current period ,other periods etc here i m entering payroll area eq 'ka' and other periods from '012006' to '122006' ,,here i want to validate the user input that it sud be of one year that is from 1 to 12.....for this i know i will use at selection event but how can i use it for the second selection screen not for first screen......... plz help me....Do u realy need the first selection screen having the current period? If u don't need then u can hide the field in the report category, by passing only the payroll area with other period, in this case we can validate through selection screen..
Reward points ... if found helpful...
Regards,
Sowmen Das -
Modify selection screen for Logical Database 'SDF'
Hi
I need to make a section of the standard selection screen for logical database 'SDF' invisible. I have tried the differet selection screen options of the report attributes, but none of the provided ones give me what I want.
How can I find the name of the screen group for the "Line Item Selection" block of the selection screen so that I can make it invisible when the selection screen is displayed?
Thanks,
ThomasI tried to do this:
Loop at screen.
if screen-group4 = '026'
or screen-group4 = '027'
or screen-group4 = '028'.
screen-invisible = 1.
modify screen.
endif.
endloop.
This removed the selection text for these fields, but the Line Item Selection block is still visible, and the actual input fields are also visible. They now look like password input fields with all ***** in them.
What am I doing wrong?
Thanks for your help!
Thomas -
Regarding LDB selection screen
Hi All,
I copied a standard LDB program "RCATSCMP".
I have a date fields in selection screen.
When i debuged the standard program i am getting the date values PN-BEGDA and PN-ENDDA.
but when iam debugging my program iam not getting any values for these fields.
How to get these values.
Thanks in Advance
kiran iHi Kiran,
Please check the attributes of the copied program
and see whether it has logical data base 'PNP' is
there are not.
Thanks & Regards,
Siri. -
Regarding At selection-screen on Radiobutton output....
Hi...
This is the code I used, to check AT SELECTION-SCREEN ON RADIOBUTTON.
But, after displaying the error message,
all fields are becoming inactive in selection screen.
CODE:
TYPES : BEGIN OF st_employee,
cid TYPE zintelli_emp-cid,
cname TYPE zintelli_emp-cname,
l ocation TYPE zintelli_emp-location,
phno TYPE zintelli_emp-phno ,
gender TYPE zintelli_emp-gender,
END OF st_employee.
DATA : it_employee TYPE STANDARD TABLE OF st_employee,
wa_employee TYPE st_employee,
v_cid TYPE zintelli_emp-cid.
SELECTION-SCREEN BEGIN OF SCREEN 500 TITLE title.
PARAMETERS : p_cid TYPE st_employee-cid obligatory.
PARAMETERS : p_cname TYPE st_employee-cname,
p_culoc TYPE st_employeelocation,
p_phno TYPE st_employee-phno.
SELECTION-SCREEN SKIP 2.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 1(6) rc1.
PARAMETERS : rb_1 RADIOBUTTON GROUP b .
SELECTION-SCREEN COMMENT 15(7) rc2.
PARAMETERS : rb_2 RADIOBUTTON GROUP b.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN SKIP 2.
SELECTION-SCREEN PUSHBUTTON /35(10) pb1 USER-COMMAND pb1.
SELECTION-SCREEN SKIP 5.
SELECTION-SCREEN END OF SCREEN 500.
CALL SELECTION-SCREEN '500'.
INITIALIZATION.
title = 'CUSTOMER INFORMATION'.
pb1 = 'INSERT'.
rc1 = 'MALE'.
rc2 = 'FEMALE'.
AT SELECTION-SCREEN ON RADIOBUTTON GROUP b.
IF rb_1 EQ 'X'.
p_cid = p_cid+0(1).
IF p_cid NE 'M'.
MESSAGE e020(z50871msg) WITH 'The id should start with "M" '.
EXIT.
ENDIF.
ELSE.
p_cid = p_cid+0(1).
IF p_cid NE 'F'.
MESSAGE e020(z50871msg) WITH 'The id should start with "F" '.
EXIT.
ENDIF.
ENDIF.
Regards
sandeep.At selection-screen on FIELD
Will give work like: If given input is wrong then it will give the Error message and all other fields will be diasable except the entered wrong on At selection-screen on FIELD.
until you give the right input it won't go for next At Selection-screen On FILED.
If you Don't want to disable other fields Use ONLY AT SELECTION-SCREEN.
Regards,
Umashankar -
Regarding At selection-screen on radiobutton
Hi..
I need sample code on AT SELECTION-SCREEN ON RADIOBUTTON.
thanx and regards
Sandeep.Hi,
Just copy paste this code and run it,
SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME.
PARAMETERS: R1 RADIOBUTTON GROUP RAD1 DEFAULT 'X',
R2 RADIOBUTTON GROUP RAD1,
R3 RADIOBUTTON GROUP RAD1.
SELECTION-SCREEN END OF BLOCK B1.
SELECTION-SCREEN BEGIN OF BLOCK B2 WITH FRAME.
PARAMETERS: R4 RADIOBUTTON GROUP RAD2 DEFAULT 'X',
R5 RADIOBUTTON GROUP RAD2,
R6 RADIOBUTTON GROUP RAD2.
SELECTION-SCREEN END OF BLOCK B2.
AT SELECTION-SCREEN ON RADIOBUTTON GROUP RAD1.
IF R1 = 'X'.
MESSAGE W040(HB).
ENDIF.
AT SELECTION-SCREEN ON RADIOBUTTON GROUP RAD2.
IF R4 = 'X'.
MESSAGE W040(HB).
ENDIF.
note: after selecting the choices press F8 and test.
hope this helps. -
Regarding passing selection screen values into internal table
Hi,
I have created one selection screen with fields
<b>POSNR LIKE VBAP-POSNR</b>
<b>SELECT-OPTIONS: s_posnr FOR vbap-posnr.</b>
I had created one internal table as:
<b>DATA: BEGIN OF i_item OCCURS 0,
posnr LIKE vbap-posnr,
END OF i_item.</b>
Now what i want is to pass what ever entries available in <b>s_posnr into i_item</b> internal table.
If user gives 10 in select-screen i_item should have 10,
If user gives 10 to 30 in select-screen i_item should have 10,20,30 entries.
If user gives nothing in s_posnr of selection screen
then i_item should have all the valid item no's[POSNR's]
from respective sales order.
Can anybody tell me how can i solve this issue!
Thanks in advance.
Thanks & Regards,
Prasad.Hi Prasad,
I guess somewhere on your selection screen there is also a parameter for sales order (eg. pa_vbeln)?
Then:
SELECT posnr
FROM vbap
INTO TABLE i_item
WHERE vbeln EQ pa_vbeln
AND posnr IN s_posnr.
Will get all position numbers in your internal table.
Regards,
John. -
HI,
On my selection screen.
I have two parameters
Param1 , Obligatory
Param2
and then two radio buttons
rad1
rad2
My requirement is if i select one radio button param 1 is mandatory
and if i select radiobutton 2 then param1 is not required.it should be grayed out.
When i tried to modify the screen in at selection-screen output
when ever i am selecting second radio button on the selection sreen i am getting a message asking for input for param 1..
How to avoid automatic checks on selection screen.
Thanks
KiranRemo obligatory for parm 1 ...(If its obligatory you should give some input to that and click on secon radio button ...)
I am giving one same code....
*& Report ZSELECTION_SCREEN_MADHU
REPORT ZSELECTION_SCREEN_MADHU NO STANDARD PAGE HEADING MESSAGE-ID ZTREE..
**& Report ZMADDY
REPORT ZMADDY NO STANDARD PAGE HEADING MESSAGE-ID ZTREE.
TABLES: MARA,MARC,VBAK ,MAKT,SSCRFIELDS.
DATA: BEGIN OF ITAB OCCURS 0 ,
SSCRFIELDS-FUNCTXT_01,
END OF ITAB.
SELECTION-SCREEN: FUNCTION KEY 1.
SELECTION-SCREEN: FUNCTION KEY 2.
SELECTION
SELECTION-SCREEN: BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.
SELECTION-SCREEN: SKIP 1.
SELECT-OPTIONS: S_MATNR FOR MARA-MATNR DEFAULT 'siva' NO-EXTENSION MODIF ID S2.
"MATCHCODE OBJECT Zmobj.
SELECT-OPTIONS: S_VBELN FOR VBAK-VBELN DEFAULT 'maddy' MODIF ID S1.
PARAMETER: P_WERKS LIKE MARC-WERKS MODIF ID S2.
PARAMETER: P_MAKTX LIKE MAKT-MAKTX MODIF ID S1.
SELECTION-SCREEN: SKIP 1.
SELECTION-SCREEN: END OF BLOCK B1.
*********radio buttons************
SELECTION-SCREEN COMMENT /1(50) comm1 MODIF ID mg1.
SELECTION-SCREEN ULINE /1(25).
*SELECTION-SCREEN SKIP.
SELECTION-SCREEN: BEGIN OF BLOCK B2 WITH FRAME TITLE TEXT-002.
SELECTION-SCREEN: BEGIN OF LINE.
PARAMETER: R1 RADIOBUTTON GROUP G2 DEFAULT 'X' USER-COMMAND UC1.
SELECTION-SCREEN : COMMENT 2(20) TEXT-021 FOR FIELD R1.
SELECTION-SCREEN: END OF LINE.
SELECTION-SCREEN: BEGIN OF LINE.
PARAMETER: R2 RADIOBUTTON GROUP G2.
SELECTION-SCREEN : COMMENT 2(10) TEXT-050 FOR FIELD R2 .
SELECTION-SCREEN :ULINE /1(10).
SELECTION-SCREEN: END OF LINE.
SELECTION-SCREEN: END OF BLOCK B2 .
INITIALIZATION.
MOVE 'HELP' TO SSCRFIELDS-FUNCTXT_01.
move 'Maddy' to sscrfields-functxt_02.
comm1 ='Select one Radio button'.
FUNCTXT_01 = 'HELP'.
AT SELECTION-SCREEN.
CASE SSCRFIELDS-UCOMM.
WHEN 'FC01'.
CALL SCREEN '101' STARTING AT 20 1
ENDING AT 90 25.
WHEN 'FC02'.
call SCREEN '102' starting at 20 1
ENDING AT 90 25.
WHEN OTHERS .
ENDCASE.
AT SELECTION-SCREEN OUTPUT.
LOOP AT SCREEN.
IF R1 = 'X' AND SCREEN-GROUP1 = 'S2'.
SCREEN-INPUT = 0.
MODIFY SCREEN.
ENDIF.
IF R2 = 'X' AND SCREEN-GROUP1 = 'S1'.
SCREEN-INPUT = 0.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
*& Module STATUS_0101 OUTPUT
text
MODULE STATUS_0101 OUTPUT.
SET PF-STATUS 'STAT'.
SET TITLEBAR 'xxx'.
ENDMODULE. " STATUS_0101 OUTPUT
*& Module USER_COMMAND_0101 INPUT
text
MODULE USER_COMMAND_0101 INPUT.
CASE SY-UCOMM.
WHEN 'CONTINUE'.
SET SCREEN 0.
LEAVE TO SCREEN 0.
WHEN 'CANCEL'.
SET SCREEN 0.
LEAVE TO SCREEN 0.
ENDCASE.
ENDMODULE. " USER_COMMAND_0101 INPUT
*& Module back INPUT
text
MODULE back INPUT.
SUBMIT ZSELECTION_SCREEN_MADHU via SELECTION-SCREEN.
ENDMODULE. " back INPUT
PLz give rewards
Maybe you are looking for
-
Adobe AE CS4 Help Menu nonfunctional
AE Help, Scripting Help, Expression Reference, Animation Presets, Keyboard Shortcuts are all nonfunctional under the Help menu. Registration, Deactivation etc. are functional. This AE is with CS4 Premium Production on Windows Vista. This has been a p
-
I am running iOS 7 on an iPad 2. There was an update for the Remote app for the Apple TV. I tried running the update and the app is now greyed out and says, "waiting". However, if I go into the App Store and view my update history, the app shows as h
-
Hp photosmart 2600 series no longer recognized by network
I have a Photosmart 2610 all-in-one printer that periodically becomes unrecognized by the network. It is connected directly via ethernet to a router, along with an Officejet 6500 E709n printer. Occasionally, the printer "disappears" from the network,
-
How to Change Store Location w/o Credit Card
how can i change my iTunes Country without the need of Credit Card? is it possible? if yes, then please tell me how
-
Writing messages to log file from database procedures
Folks, Is there a way by which I will be able to write messages from a database procedure to a log file? I would like to know what a procedure is doing and if it has failed or suceeded just as we do in a Unix shell script where we can direct messages