Skip to Content
author's profile photo Former Member
Former Member

selection screen

Hi frnds,

This is my selection screen.

<code>

selection-screen begin of block b1 with frame title text-001.

selection-screen begin of block b2 with frame title text-002.

select-options : s_AUDAT for vbak-audat obligatory,

s_VBELN for vbak-vbeln,

s_KUNNR for vbak-kunnr.

selection-screen end of block b2.

SELECTION-SCREEN BEGIN OF BLOCK B3 WITH FRAME TITLE TEXT-003.

SELECTION-SCREEN BEGIN OF LINE.

  • Presentation sys radio button

PARAMETERS : P_PS TYPE C RADIOBUTTON GROUP RAD1.

SELECTION-SCREEN COMMENT 4(20) TEXT-004 FOR FIELD P_PS.

  • Presentation sys file path

PARAMETERS: P_FILE1 TYPE IBIPPARMS-PATH .

SELECTION-SCREEN END OF LINE.

SELECTION-SCREEN BEGIN OF LINE.

  • Application Server radio button

PARAMETERS : P_AS TYPE C RADIOBUTTON GROUP RAD1.

SELECTION-SCREEN COMMENT 4(20) TEXT-005 FOR FIELD P_AS.

  • Application server file path

PARAMETERS: P_FILE2 TYPE DXFIELDS-LONGPATH .

SELECTION-SCREEN END OF LINE.

SELECTION-SCREEN END OF BLOCK B3 .

PARAMETERS:P_EMAIL AS CHECKBOX.

selection-screen end of block b1.

</code>

My requirement is whenever i will go to selection screen

P_AS (Application server ) should come by default disabled.

regards,

satya

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

4 Answers

  • Posted on Jan 31, 2008 at 04:03 PM

    make the sy-ucom defaulted to that variable.

    keep a loop at screen

    disable the group id of it.

    endloop.

    Ex:

    PARAMETERS: pa_logic RADIOBUTTON GROUP e1 USER-COMMAND inv DEFAULT 'X',
    pa_equip RADIOBUTTON GROUP e1,
    pa_ob RADIOBUTTON GROUP e1.
    
    PARAMETERS: pa_zpms AS CHECKBOX MODIF ID i1.
    -------------------------------
    AT SELECTION-SCREEN OUTPUT.
    
    IF pa_equip <> 'X'.
    LOOP AT SCREEN.
    IF screen-group1 = 'I1'.
    screen-active = 0.
    MODIFY SCREEN.
    ENDIF.
    ENDLOOP.
    ENDIF.
    
    IF pa_logic <> 'X'.
    LOOP AT SCREEN.
    IF screen-group1 = 'I2'.
    screen-active = 0.
    MODIFY SCREEN.
    ENDIF.
    ENDLOOP.
    ENDIF.

    check this code.. you can do it..

    Edited by: Jay S on Jan 31, 2008 11:06 AM

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      Check the below code :

      REPORT ZTEST76 .

      tables : vbak.

      selection-screen begin of block b1 with frame title text-001.

      selection-screen begin of block b2 with frame title text-002.

      select-options : s_AUDAT for vbak-audat obligatory,

      s_VBELN for vbak-vbeln,

      s_KUNNR for vbak-kunnr.

      selection-screen end of block b2.

      SELECTION-SCREEN BEGIN OF BLOCK B3 WITH FRAME TITLE TEXT-003.

      SELECTION-SCREEN BEGIN OF LINE.

      *Presentation sys radio button

      PARAMETERS : P_PS TYPE C RADIOBUTTON GROUP RAD1.

      SELECTION-SCREEN COMMENT 4(20) TEXT-004 FOR FIELD P_PS.

      *Presentation sys file path

      PARAMETERS: P_FILE1 TYPE IBIPPARMS-PATH .

      SELECTION-SCREEN END OF LINE.

      SELECTION-SCREEN BEGIN OF LINE.

      *Application Server radio button

      PARAMETERS : P_AS TYPE C RADIOBUTTON GROUP RAD1.

      SELECTION-SCREEN COMMENT 4(20) TEXT-005 FOR FIELD P_AS.

      *Application server file path

      PARAMETERS: P_FILE2 TYPE DXFIELDS-LONGPATH .

      SELECTION-SCREEN END OF LINE.

      SELECTION-SCREEN END OF BLOCK B3 .

      PARAMETERS:P_EMAIL AS CHECKBOX.

      selection-screen end of block b1.

      *</code>

      at selection-screen output.

      loop at screen.

      • Disable radio button

      if screen-name = 'P_AS'.

      screen-input = 0.

      modify screen.

      endif.

      • Disable file path

      if screen-name = 'P_FILE2'.

      screen-input = 0.

      modify screen.

      endif.

      endloop.

      Thanks

      Seshu

  • author's profile photo Former Member
    Former Member
    Posted on Jan 31, 2008 at 04:28 PM
    TABLES : vbak.
    SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.
    
    SELECTION-SCREEN BEGIN OF BLOCK b2 WITH FRAME TITLE text-002.
    
    SELECT-OPTIONS : s_audat FOR vbak-audat OBLIGATORY,
    s_vbeln FOR vbak-vbeln,
    s_kunnr FOR vbak-kunnr.
    
    SELECTION-SCREEN END OF BLOCK b2.
    
    SELECTION-SCREEN BEGIN OF BLOCK b3 WITH FRAME TITLE text-003.
    
    SELECTION-SCREEN BEGIN OF LINE.
    
    *Presentation sys radio button
    PARAMETERS : p_ps TYPE c RADIOBUTTON GROUP rad1 DEFAULT 'X'
    USER-COMMAND umd .
    SELECTION-SCREEN COMMENT 4(20) text-004 FOR FIELD p_ps.
    
    *Presentation sys file path
    PARAMETERS: p_file1 TYPE ibipparms-path .
    SELECTION-SCREEN END OF LINE.
    
    SELECTION-SCREEN BEGIN OF LINE.
    
    *Application Server radio button
    PARAMETERS : p_as TYPE c RADIOBUTTON GROUP rad1 .
    SELECTION-SCREEN COMMENT 4(20) text-005 FOR FIELD p_as.
    
    *Application server file path
    PARAMETERS: p_file2 TYPE dxfields-longpath  MODIF ID mod.
    SELECTION-SCREEN END OF LINE.
    
    SELECTION-SCREEN END OF BLOCK b3 .
    PARAMETERS:p_email AS CHECKBOX.
    SELECTION-SCREEN END OF BLOCK b1.
    
    
    AT SELECTION-SCREEN OUTPUT.
    
      LOOP AT SCREEN.
        IF screen-group1 = 'MOD' AND p_ps = 'X'.
          screen-input = 0.
          MODIFY SCREEN.
        ELSEIF  screen-group1 = 'MOD' AND p_as = 'X'.
          screen-input = 1.
          MODIFY SCREEN.
        ENDIF.
    
      ENDLOOP.
    
    
    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 31, 2008 at 04:42 PM

    Hi Satya,

    To me it doesnt make sense to disable one radiobutton out of two in the radiobutton group.

    Also, if you want to make it disable when should it be active again?

    You can try handling one of the below two examples:

    1. Declare one Text field for Filename and use it accoringly w.r.t the radiobutton selected.

    Eg:

    * Presentation sys radio button 
        PARAMETERS : P_PS TYPE C RADIOBUTTON GROUP RAD1.
        SELECTION-SCREEN COMMENT 4(20) TEXT-004 FOR FIELD P_PS.
    
    * Application Server radio button 
        PARAMETERS : P_AS TYPE C RADIOBUTTON GROUP RAD1.
        SELECTION-SCREEN COMMENT 4(20) TEXT-005 FOR FIELD P_AS.
    
    * File Name
        PARAMETERS: p_file TYPE RLGRAP-FILENAME.
    
    " So when radiobutton P_PS is selected P_FILE takes the input for filepath of Presentation server else Application Server
    

    2. Make the text box correponding to the radiobutton active/inactive.

    Eg:

     SELECTION-SCREEN BEGIN OF BLOCK B3 WITH FRAME TITLE TEXT-003.
    
       SELECTION-SCREEN BEGIN OF LINE.
    
    * Presentation sys radio button 
        PARAMETERS : P_PS TYPE C RADIOBUTTON GROUP RAD1 USER-COMMAND ABC.
           " Note the addition User-Command to trigger action when radio button is changed
        SELECTION-SCREEN COMMENT 4(20) TEXT-004 FOR FIELD P_PS.
    
    *  Presentation sys file path 
       PARAMETERS: P_FILE1 TYPE IBIPPARMS-PATH .
       SELECTION-SCREEN END OF LINE.
    
      SELECTION-SCREEN BEGIN OF LINE.
    
    * Application Server radio button 
        PARAMETERS : P_AS TYPE C RADIOBUTTON GROUP RAD1.
        SELECTION-SCREEN COMMENT 4(20) TEXT-005 FOR FIELD P_AS.
    
    * Application server file path 
        PARAMETERS: P_FILE2 TYPE DXFIELDS-LONGPATH .
        SELECTION-SCREEN END OF LINE.
    
    .....
    
    AT SELECTION-SCREEN OUTPUT.
    
      LOOP AT screen.
    
        IF screen-name CP '*P_FILE1*'.
            IF NOT p_ps IS INITIAL.
                screen-active = 1.
            ELSE.
                screen-active = 0.
            ENDIF.
            MODIFY screen.
        ELSEIF screen-name CP '*P_FILE2*'.
            IF p_ps IS INITIAL.
                screen-active = 1.
            ELSE.
                screen-active = 0.
            ENDIF.
            MODIFY screen.
        ENDIF.        
    
      ENDLOOP.
    
    

    Regards

    Eswar

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 31, 2008 at 06:09 PM

    Hi,

    Please find sample 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.
          else.
          IF screen-group1 = 'SP2'.
            screen-input = '0'.
            screen-invisible = '0'.
            screen-required = '0'.
            MODIFY SCREEN.
          ENDIF.
    endif.
        ENDLOOP.
    

    Thanks,

    Sriram Ponna.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.