Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

at selection screen

Former Member
0 Likes
538

hi gurus at selection screen . i want to desable some fields on the selection screen how it is plz tell me code

4 REPLIES 4
Read only

Former Member
0 Likes
515

Hi,

Check this link..

http://help.sap.com/saphelp_nw70/helpdata/en/9f/dba6aa35c111d1829f0000e829fbfe/content.htm

PARAMETERS p ...... NO-DISPLAY ......

<removed by moderator>

Regards,

Sowmya

Edited by: Mike Pokraka on Aug 4, 2008 6:54 PM

Read only

Former Member
0 Likes
515

Hi ,

you can do it by using .....NO DISPLAY ADDITION to the PARAMETERS.

For details you may check the following extract from SAP HELP

Hiding Input Fields  
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.

Regards,

anirban

Read only

Former Member
0 Likes
515

Hi,

You can do screen modifications in the event At selection-screen output.

parameters: p_field modification group 'MOD'.

at selection-screen output.

if screen-group1 = 'MOD'.

loop at screen.

screen-input = 0.

endloop.

endif.

Reward if helpful.

Read only

Former Member
0 Likes
515

Hii!

Check out this sample code


REPORT z_sdn.
 
PARAMETERS:
  p_num RADIOBUTTON GROUP rad1 DEFAULT 'X' USER-COMMAND abc,
  p_char RADIOBUTTON GROUP rad1.
 
PARAMETERS:
  p_num1 TYPE i MODIF ID num,
  p_num2 TYPE i MODIF ID num,
  p_char1 TYPE c MODIF ID chr,
  p_char2 TYPE c MODIF ID chr.
 
 
AT SELECTION-SCREEN OUTPUT.
  IF p_num EQ 'X'.
    LOOP AT SCREEN.
      IF screen-group1 EQ 'CHR'.
        screen-active = 0.
        MODIFY SCREEN.
      ENDIF.
    ENDLOOP.
  ELSE.
    LOOP AT SCREEN.
      IF screen-group1 EQ 'NUM'.
        screen-active = 0.
        MODIFY SCREEN.
      ENDIF.
    ENDLOOP.
  ENDIF.

Regards

Abhijeet