Designing Selection Screen objects

Hello,
I have the requirement of having a checkbox (p_header) and parameter filepath (p_file) on the same line along with the text decription i.e. p_header and P_file.
It should be like this
__ p_header     P-file ________________
But I am only getting the checkbox and the p_file path...not the text decription as seen below:
My code is as below:
SELECTION-SCREEN BEGIN OF BLOCK p2 WITH FRAME TITLE text-503.
SELECTION-SCREEN BEGIN OF LINE.
     PARAMETERS: p_header AS CHECKBOX.
     SELECTION-SCREEN COMMENT 4(17) text-a01 FOR FIELD p_header.
     SELECTION-SCREEN POSITION POS_LOW.
     PARAMETERS : p_file3 LIKE filename-fileintern OBLIGATORY
                              DEFAULT 'FILEPATH_xx.OUT'.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN END OF BLOCK p2.
I hope my requirement is clear enough.
I have included text-a01 in Goto->Text symbols and activated, but I am not getting the text on selection screen.
Would truly appreciate your help.

Hello Alita,
Check with the below code.
SELECTION-SCREEN BEGIN OF BLOCK p2 WITH FRAME TITLE text-004.
SELECTION-SCREEN BEGIN OF LINE.
     PARAMETERS: p_header AS CHECKBOX.
     SELECTION-SCREEN COMMENT 4(9) text-005.
     SELECTION-SCREEN COMMENT 20(7) text-006.
     PARAMETERS : p_file3 LIKE filename-fileintern OBLIGATORY
                              DEFAULT 'FILEPATH_xx.OUT'.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN END OF BLOCK p2.
How to use the SELECTION SCREEN COMMENT.
SELECTION-SCREEN COMMENT <no. of position to skip from starting of line>(<length of the variable>) text-005.
Regards,
Thanga

Similar Messages

  • How to design selection screen with WAD 3.x Web Items

    Hi Guruu2019s,
    I have a requirement where I need to design a selection screen by using WAD 3.x web items. In the selection screen we have to include the Query Description - in the left corner of the selection screen, Name of Sales Person u2013 left side of the screen, Date from and Date to u2013 right side of the selection screen, User ID and User Name u2013 on the top right of the selection screen etc., after this on the bottom of the selection screen I have to include the pushbutton RUN REPORT.
    After filling all the above parameters and click on Run Report it has to trigger another URL link which contains consolidated Sales CRM Report.
    Could any one suggest me and provide me the idea on developing the selection screen with WAD 3.x Web items and is there any other interface to trigger the other URL link when I click on Run Report.
    Regards
    Venkat

    no replies. Closing the incident

  • Problem in designe selection screen

    Hi Experts,
                    i have to design a selection screen like
    Month ->  january to sepetmber
    tear ->     2005  to current year
    i am using the field delivery_date for this purpose(which has no data element). the field is dats and lenth 8 it contains value like 01.01.2005.
    how could i make this possible. please hep me out.
    Thank you for the help.

    Hi,
    You can use VRM_SET_VALUES for this requirement.
    Thanks & Regards,
    Vamsi.

  • In designing selection screen

    hi
    in selectio screen , i have two parameters
    p_vbeln , p_audat. only one input i have to enter.
    if p_vbeln is entered p_audat must become greyed (should not allow input).
    if p_audat is entered p_vbeln should be greyed

    hi
    you can do this at selection-screen output event block
    you can write a code for it..
    at selection-screen ouput.
    if not p_vbeln is initial.
    loop at screen.
      if screen-name = 'P_VBELN'.
        screen-active = '0'.  
      endif.
      if screen-name = 'P_AUDAT'.
      screen-active = '1'.
      endif.
    modify screen.
    endloop.
    elseif not p_audat is initial.
      loop at screen.
      if screen-name = 'P_VBELN'.
        screen-active = '1'.  
      endif.
      if screen-name = 'P_AUDAT'.
      screen-active = '0'.
      endif.
    modify screen.
    endloop.
    endif.
    hope this code wil help u out..
    if yes let me know..

  • Problem in designing selection screen

    Hi friends...............
    Based on one radio button i need ti disable some Mandaory fields (those are Mandaory fields).
    But here i cant overcome these mandatory fields.
    How can i do this.

    Hi,
    use the following code
    selection-screen begin of block blk11 with frame title text-002.
    *parameters : so_plant radiobutton group a USER-COMMAND fcod MODIF ID m1 DEFAULT 'X'.
    *parameters : so_ven   radiobutton group a MODIF ID m1 .
    *parameters : so_cust  radiobutton group a MODIF ID m1.
    *selection-screen end of block blk11.
    *at selection-screen OUTPUT .
    PERFORM chng_screen.
    *AT SELECTION-SCREEN.
    LOOP AT SCREEN.
       IF screen-group1 = 'M2'.
          IF screen-input NE '1'.
            v_flag = 'X'.
          ELSE.
            clear v_flag.
          ENDIF.
       ENDIF.
    endloop.
    *form chng_screen.
    *LOOP AT  SCREEN.
    if so_plant = 'X'.
      IF screen-group1 = 'M3'.
         screen-input = space.
         screen-active = 0.
         modify screen.
      ELSEIF  screen-group1 = 'M2'.
         screen-input = 1.
         screen-active = 1.
         modify screen.
      ELSEIF screen-group1 = 'M4'.
         screen-input = 1.
         screen-active = 0.
         modify screen.
       ENDIF.
    ELSEIF SO_VEN = 'X'.
      IF screen-group1 = 'M2'.
         screen-input = space.
         screen-active = 0.
         modify screen.
      elseif screen-group1 = 'M3'.
         screen-input = 1.
         screen-active = 1.
         modify screen.
      ELSEIF screen-group1 = 'M4'.
         screen-input = 1.
         screen-active = 0.
         modify screen.
       ENDIF.
    ELSEIF SO_CUST = 'X'.
       IF screen-group1 = 'M2'.
         screen-input = space.
         screen-active = 0.
         modify screen.
      ELSEIF screen-group1 = 'M3'.
         screen-input = 1.
        screen-active = 0.
         modify screen.
      ELSEIF screen-group1 = 'M4'.
         screen-input = 1.
        screen-active = 1.
         modify screen.
       ENDIF.
    ENDIF.
    *ENDLOOP.
    Thanks & Regards

  • F4 help for the selection screen field designed in screen painter

    Hi all,
    I have designed selection screen in the screen painter. in that for one of the fields i have to give f4 help. for that i have writter the code in PAI event. in this event i have used the standard Function module for f4 help. but no f4 help is comming for that field. can any body suggest what i have to do.
    Thanks & Regards,
    Giri.

    Hi,
    You must use the correct event to meet ur requirement use  POV event instead of  PAI event.
    for more clarification and example program see  below the demo program
    DEMO_DYNPRO_F4_HELP_DYNPRO
    DEMO_DYNPRO_F4_HELP_MODULE
    Cheers
    fareed

  • WHAT IS ACTUALLY SELECTION SCREEN

    WHEN DOES ACTUALLY SELECTION SREEN WILL BE EXECUTED ACCORDING TO PRIORITY.

    Hai Raghu
    Go through the following Document
    SELECTION-SCREEN
    Variants
    1. SELECTION-SCREEN BEGIN OF LINE.
    2. SELECTION-SCREEN END OF LINE.
    3. SELECTION-SCREEN SKIP n.
    4. SELECTION-SCREEN ULINE.
    5. SELECTION-SCREEN POSITION pos.
    6. SELECTION-SCREEN COMMENT fmt name.
    7. SELECTION-SCREEN PUSHBUTTON fmt name USER-COMMAND ucom.
    8. SELECTION-SCREEN BEGIN OF BLOCK block.
    9. SELECTION-SCREEN END OF BLOCK block.
    10. SELECTION-SCREEN FUNCTION KEY n.
    11. SELECTION-SCREEN BEGIN OF VERSION ver TEXT-xxx.
    12. SELECTION-SCREEN END OF VERSION ver.
    13. SELECTION-SCREEN EXCLUDE ... .
    14. SELECTION-SCREEN DYNAMIC SELECTIONS FOR TABLE dbtab.
    15. SELECTION-SCREEN FIELD SELECTION FOR TABLE dbtab.
    <b>Effect
    The key word SELECTION-SCREEN only makes sense in reports, i.e. programs specified as type "1" in the attributes. You use it to design the selection screen in the program or logical database access routine.
    The selection screen is normally generated from the SELECT-OPTIONS and PARAMETERS statements in the report and logical database access routine. Each of these objects occupies a separate line on the selection screen.
    SELECTION-SCREEN allows you to form blocks, combine several parameters and comments together on one line, generate pushbuttons on the screen or activate them in the application toolbar, as well as insert blank lines, underscore lines and comments.
    Like SELECT-OPTIONS and PARAMETERS , you can use SELECTION-SCREEN statements in reports and in the include program DBldbSEL of the logical database ldb assigned to the report in the attributes. Some variants are defined only for logical databases and can therefore only be used in the include program DBldbSEL .</b>
    Variant 1
    SELECTION-SCREEN BEGIN OF LINE.
    Variant 2
    SELECTION-SCREEN END OF LINE.
    Effect
    Allows you to combine several parameters and comments specified between the SELECTION-SCREEN BEGIN OF LINE and SELECTION-SCREEN END OF LINE statements and output them on one line. As a result, there is no automatic new line for each PARAMETER and no selection texts are displayed.
    Example
    SELECTION-SCREEN BEGIN OF LINE.
      SELECTION-SCREEN COMMENT 1(10) TEXT-001.
      PARAMETERS: P1(3), P2(5), P3(1).
    SELECTION-SCREEN END OF LINE.
    Selection screen:
    Comment ___ _____ _
    Note
    You cannot order SELECT-OPTIONS between SELECTION-SCREEN BEGIN OF LINE and SELECTION-SCREEN END OF LINE because several objects are generated on the selection screen for a SELECT-OPTION (e.g. fields for the lower and upper limits of ranges).
    Variant 3
    SELECTION-SCREEN SKIP n.
    Additions
    1. ... FOR TABLE dbtab
    2. ... ID id
    Effect
    Generates n blank lines (see also SKIP ).
    You must specify a value for n between 1 and 9. If you want to output just one blank line, you can omit n .
    Addition 1
    ... FOR TABLE dbtab
    Effect
    This addition is allowed only in the database include program DBldbSEL . It is, in fact, a requirement. If you use SELECTION-SCREEN SKIP in DBldbSEL , you must assign the statement to a table (or to a field - see the variant COMMENT .
    This assignment is necessary in order to restrict the SELECTION-SCREEN statements for a report selection screen to those relevant for the tables used in the report, i.e. those which refer to a table used in the report. Any SELECTION-SCREEN statement assigned to a table not used in the report with the addition FOR TABLE dbtab are ignored when the report selection screen is generated.
    Note
    A table dbtab of the logical database ldb is considered as "used in the report" if it is either declared in a TABLES statement or its position in the database hierarchy lies somewhere between the root and a table dbtab_2 declared in the report.
    Example
    Hierarchy of logical database ldb :
    SPFLI
      SAPLANE
      SFLIGHT
                    |
      SBOOK
    In the report:
    TABLES SFLIGHT.
    Tables considered as "used" include  SFLIGHT  (since it is
    declared directly), as well as  SAPLANE  and  SPFLI  (since
    they lie on the path from the hierarchy root " SPFLI " to the
    declared table  SFLIGHT ). The table  SBOOK  is not
    considered  as used, i.e. all the  SELECTION-SCREEN  statements
    qualified with the addition " FOR TABLE SBOOK " in  DBldbSEL
    are ignored.
    Addition 2
    ... ID id
    Effect
    This addition is allowed only in the database include program DBldbSEL . It is used to identify a SELECTION-SCREEN object (in this case blank lines) via an ID which can be up to 3 characters long. This ID is then specified in SELECTION-SCREEN EXCLUDE IDS id in order to exclude the object from a selection screen version.
    Variant 4
    SELECTION-SCREEN ULINE.
    Additions
    1. ... fmt
    2. ... FOR TABLE dbtab
    3. ... MODIF ID mod
    4. ... ID id
    Effect
    Generates an underline (see also ULINE ).
    Addition 1
    ... fmt
    Effect
    Format specification with the form /pos(len) , pos(len) or (len) . The slash ( / ) generates a new line and is therefore not allowed between BEGIN OF LINE and END OF LINE . The effect of the statement is to underscore the current line starting from the position pos for the length len . The variant (len) (without position specification) is allowed only between BEGIN OF LINE and END OF LINE . In this case, the current position in the line is used. See also WRITE .
    You can specify the position pos as a number (in this case, it is relative to the frame if the statement comes between SELECTION-SCREEN BEGIN OF BLOCK ... WITH FRAME ... and SELECTION-SCREEN END OF BLOCK ... ). Also allowed are the symbolic positions POS_LOW and POS_HIGH . These are the positions at which the input fields of the SELECT-OPTI ONS are output ( POS_LOW is also the position of PARAMETERS .
    Note
    Format specifications which do not generate a new line can produce overlapping objects on the selection screen. Therefore, you should be particularly careful with position and length specifications.
    Example
    SELECTION-SCREEN ULINE /1(10).
    SELECTION-SCREEN ULINE POS_LOW(10).
    SELECTION-SCREEN ULINE POS_HIGH(10).
    This generates three underscore blocks, each with a length of 10, on one line.
    Addition 2
    ... FOR TABLE dbtab
    Effect
    See variant 3 ( SELECTION-SCREEN SKIP ).
    Addition 3
    ... MODIF ID mod
    Effect
    The specified modification group ( SCREEN-GROUP1 ) is assigned to the underscore. You can use this under AT SELECTION-SCREEN in the report or in the PAI routine of the database program SAPDBldb to modify the screen.
    Note
    The name of the modification group must be specified without quotation marks. It can be up to three characters long.
    Addition 4
    ... ID id
    Effect
    See variant 3 ( SELECTION-SCREEN SKIP )
    Variant 5
    SELECTION-SCREEN POSITION pos.
    Addition
    ... FOR TABLE dbtab
    Effect
    Outputs the parameter starting from the position pos .
    This variant is allowed only between SELECTION-SCREEN BEGIN OF LINE< /> and SELECTION-SCREEN END OF LINE .
    As with the addition ULINE , you can specify the position as fixed (if necessary relative to the frame) or symbolically in the form POS_LOW or POS_HIGH .
    Addition
    ... FOR TABLE dbtab
    Effect
    See variant 3 ( SELECTION-SCREEN SKIP )
    Variant 6
    SELECTION-SCREEN COMMENT fmt name.
    Additions
    1. ... FOR TABLE dbtab
    2. ... FOR FIELD f
    3. ... MODIF ID mod
    4. ... ID id
    Effect
    Generates a comment on the selection screen. For the name name , there are two options:
    name takes the form TEXT-xxx where xxx is a three-character name for a text symbol. In this case, the contents of the text symbol are displayed at runtime, i.e. the text cannot be changed dynamically. name is another eight-character name. Here, you create a field with the name name in the length specified in the format fmt< /> and it is then generated as an output field on the selection screen. The contents of these comments must therefore be set at runtime (e.g. at INITIALIZATION or - in the case of comments in the database include program DBldbSEL - in the routine INIT of the database program SAPDBldb . They can also be changed when the selection screen is being processed.
    Note
    The field name is generated automatically and so cannot be defined with DATA .
    With comments, you must always specify a format fmt (see variant ULINE ).
    Note
    You must program a new line yourself via the format fmt .
    Addition 1
    ... FOR TABLE dbtab
    Note
    See variation 3 (SELECTION-SCREEN SKIP).
    Addition 2
    ... FOR FIELD f
    Effect
    Since the comment is assigned to a parameteror a select-option , the help display shows the documentation of the reference field if this parameter or selection option.
    In addition, the comment is suppressed if the reference object was set to 'invisible' via a selection variant.
    Note
    In database access routines, the comment is generated whenever the reference field is output. Therefore, you should not use the addition FOR TABLE with this variant.
    Example
    SELECTION-SCREEN BEGIN OF LINE.
      SELECTION-SCREEN COMMENT 10(20) TEXT-001
                       FOR FIELD PARM.
      SELECTION-SCREEN POSITION POS_LOW.
      PARAMETERS PARM LIKE SAPLANE-PLANETYPE.
    SELECTION-SCREEN END OF LINE.
    This code displays a 20-byte long comment followed by the parameter at the normal position ( POS_LOW ) on the same line. If the user presses F1 for both objects, the documentation of SAPLANE-PLANETYPE is displayed.
    Addition 3
    ... MODIF ID mod
    Effect
    See variant 4 ( SELECTION-SCREEN ULINE )
    Addition 4
    ... ID id
    Effect
    See variant 3 ( SELECTION-SCREEN SKIP )
    Variant 7
    SELECTION-SCREEN PUSHBUTTON fmt name USER-COMMAND ucom.
    Additions
    1. ... FOR TABLE dbtab
    2. ... MODIF ID mod
    3. ... ID id
    Effect
    Generates a pushbutton on the selection screen. Also specified is the user command ucom (without quotation marks) which can be up to 4 characters long. This is generated when the user presses the button. Apart from this, the syntax is largely similar to that of SELECTION-SCREEN COMMENT :
    For the name name , there are two options:
    name takes the form TEXT-xxx where xxx is a three-character name for a text symbol. In this case, the contents of the text symbol are displayed at runtime, i.e. the text cannot be changed dynamically. name is another eight-character name. Here, you create a field with the name name in the length specified in the format fmt< /> and it is then generated as an output field on the selection screen. The contents of these comments must therefore be set at runtime (e.g. at INITIALIZATION or - in the case of comments in the database include program DBldbSEL - in the routine INIT of the database program SAPDBldb . They can also be changed when the selection screen is being processed.
    Note
    The field name is generated automatically and so cannot be defined with DATA .
    With pushbuttons, you must always specify a format fmt (see variant ULINE ).
    Note
    You must program a new line yourself via the format fmt .
    The best way to respond to the user pressing the pushbutton is in the event AT SELECTION-SCREEN or - in the case of pushbuttons in the database include program DBldbSEL - in the routine PAI (with FNAME = '*' and MARK = SPACE ) in the database program SAPDBldb . Here, the field SSCRFIELDS-UCOMM contains the user command ucom (the table SSCRFIELDS must be declared with the TABLES statement).
    Addition 1
    ... FOR TABLE dbtab
    Effect
    See variant 3 ( SELECTION-SCREEN SKIP )
    Addition 2
    ... MODIF ID mod
    Effect
    See variant 4 ( SELECTION-SCREEN ULINE )
    Addition 3
    ... ID id
    Effect
    See variant 3 ( SELECTION-SCREEN SKIP )
    Example
    TABLES SSCRFIELDS.
    SELECTION-SCREEN PUSHBUTTON /10(20) CHARLY USER-COMMAND ABCD.
    INITIALIZATION.
      MOVE 'My text' TO CHARLY.
    AT SELECTION-SCREEN.
      IF SSCRFIELDS-UCOMM = 'ABCD'.
      ENDIF.
    The selection screen displays a pushbutton with the text 'My text' . With AT SELECTION-SCREEN , the field SSCRFIELDS-UCOMM contains ABCD after the user has pressed the button.
    Variant 8
    SELECTION-SCREEN BEGIN OF BLOCK block.
    Additions
    1. ... WITH FRAME
    2. ... TITLE title
    3. ... NO INTERVALS
    Effect
    Starts a logical block on the selection screen. If you use the addition WITH FRAME , a frame is generated around the block. The addition TITLE title is allowed only in conjunction with WITH FRAME .
    For the title title ,there are two options (see also the variants COMMENT and PUSHBUTTON ):
    title takes the form TEXT-xxx where xxx is a three-character name for a text symbol. In this case, the contents of the text symbol are displayed at runtime, i.e. the text cannot be changed dynamically. title is another eight-character name. Here, you create a field with the name title in the length specified in the format fmt< /> and it is then generated as an output field on the selection screen. The contents of these comments must therefore be set at runtime (e.g. at INITIALIZATION or - in the case of comments in the database include program DBldbSEL - in the routine INIT of the database program SAPDBldb . They can also be changed when the selection screen is being processed.
    Note
    The field title is generated automatically and so cannot be defined with DATA .
    At runtime, the event AT SELECTION-SCREEN ON BLOCK block is executed for every block in the PAI module of the selection screen (with database- specific blocks, the PAI module in the program SAPDBldb is also executed with the parameters FNAME = BLOCK_block and MARK = SPACE ). If this produces an error message, just the fields of this block are ready for input.
    You can nest blocks. The maximum nesting depth for blocks with frames is 5.
    Addition 3
    ... NO INTERVALS
    Effect
    Displays all SELECT-OPTIONS within the block in simplified form without a 'to' field on the selection screen (like the addition " NO INTERVALS " with SELECT-OPTIONS ). If the block has a frame, this is correspondingly small.
    Note
    In the case of blocks without frames, the attribute " NO INTERVALS " is not inherited by subordinate blocks. However, all subordinate blocks of blocks with frames inherit this attribute because the generated frame is smaller and there is no space for the 'to' field.
    Variant 9
    SELECTION-SCREEN END OF BLOCK block.
    Effect
    Closes the block opened by SELECTION-SCREEN BEGIN OF BLOCK block . If the block has a frame, the frame is closed here. Blocks opened in the include program DBldbSEL must also be closed there.
    Note
    Blocks defined in the database include program DBldbSEL must also be close there. As with SELECTION-SCREEN BEGIN OF LINE and SELECTION-SCREEN END OF LINE , you cannot use the addition FOR TABLE with blocks. Instead, the objects in the blocks (selection options , parameters , comments, underscores ...) are omitted if the table to which they belong is not used in the report (see note under variant SELECTION-SCREEN SKIP ). Empty blocks (possibly with frames) are also omitted.
    Example
    TABLES SAPLANE.
    SELECTION-SCREEN BEGIN OF BLOCK CHARLY
                     WITH FRAME TITLE TEXT-001.
      PARAMETERS PARM(5).
      SELECT-OPTIONS SEL FOR SAPLANE-PLANETYPE.
    SELECTION-SCREEN END   OF BLOCK CHARLY.
    (Let TEXT-001 contain 'Block Charly' ).
    Selection screen:
    Block Charly--
    PARM _____
    | SEL ________ bis ________ |
    Variant 10
    SELECTION-SCREEN FUNCTION KEY n.
    Additions
    1. ... FOR TABLE dbtab
    2. ... ID id
    Effect
    With this variant, you can activate up to 5 function keys in the application toolbar on the selection screen ( n is one of the numbers 1 to 5).
    At runtime, the text must be placed in the Dictionary field SSCRFIELDS-FUNCTXT_01 or ... SSCRFIELDS-FUNCTXT_05 .
    The function code placed in the field SSCRFIELDS-UCOMM is 'FC01' or ... 'FC05' . You can read this function code under AT SELECTION-SCREEN or in the PAI module of the database access program SAPDBldb .
    Addition 1
    ... FOR TABLE dbtab
    Effect
    See variant 3 ( SELECTION-SCREEN SKIP )
    Addition 2
    ... ID id
    Effect
    See variant 3 ( SELECTION-SCREEN SKIP )
    Example
    TABLES SSCRFIELDS.
    SELECTION-SCREEN FUNCTION KEY 1.
    INITIALIZATION.
      MOVE 'My text' TO SSCRFIELDS-FUNCTXT_01.
    AT SELECTION-SCREEN.
      IF SSCRFIELDS-UCOMM = 'FC01'.
      ENDIF.
    The selection screen displays a pushbutton with the text 'My text' . With AT SELECTION-SCREEN , the field SSCRFIELDS-UCOMM contains FC01 after the user has pressed the button.
    Variant 11
    SELECTION-SCREEN BEGIN OF VERSION ver TEXT-xxx.
    Variant 12
    SELECTION-SCREEN END OF VERSION ver.
    Variant 13
    SELECTION-SCREEN EXCLUDE ... .
    Effect
    Defines a selection screen version (with a three-character name ver ). These variants are only allowed in the database include program DBldbSEL . Between BEGIN OF VERSION and END OF VERSION , you can exclude selection screen objects for the version ver , i.e. remove them from the selection screen with SELECTION-SCREEN EXCLUDE. .
    For a report, you activate a selection screen by making an entry in the attributes. If the database access program SAPDBldb itself has a selection screen version in the attributen, this applies for all reports which use this logical database and have attributes where no separate selection screen version is declared.
    The text symbol TEXT -xxx is used merely to facilitate selection of a selection screen version via F4 help when maintaining the attributes.
    Additions
    (to SELECTION-SCREEN EXCLUDE )
    1. ... PARAMETERS par
    2. ... SELECT-OPTIONS sel
    3. ... RADIOBUTTON GROUPS radi
    4. ... BLOCKS block
    5. ... IDS id
    Effect
    Excludes selection screen objects between SELECTION-SCREEN BEGIN and END OF VERSION . This allows you to exclude individual parameters or selection options , radiobutton groups , blocks defined by SELECTION-SCREEN BEGIN/END OF BLOCK and other objects such as comments and underscores specified by the addition ID id .
    Note
    The database program SAPDBldb can get the active version for the current report with the function module RS_SELSCREEN_VERSION .
    Example
    PARAMETERS PAR_1 LIKE dbfield_1 FOR TABLE dbtab_1.
    SELECT-OPTIONS SEL_1 FOR dbfield_01.
    SELECT-OPTIONS SEL_2 FOR dbfield_02.
    SELECT-OPTIONS SEL_3 FOR dbfield_03.
    SELECTION-SCREEN COMMENT /10(20) TEXT-100 FOR TABLE dbtab_1 ID 001.
    SELECTION-SCREEN COMMENT /8(30) TEXT-200 FOR TABLE dbtab_2 ID 002.
    PARAMETERS PAR_2 LIKE dbfield_1 FOR TABLE dbtab_2.
    PARAMETERS PAR_3 LIKE dbfield_1 FOR TABLE dbtab_2.
    SELECTION-SCREEN BEGIN OF VERSION ABC TEXT-008.
    SELECTION-SCREEN EXCLUDE PARAMETERS: PAR_1, PAR_3.
    SELECTION-SCREEN EXCLUDE SELECT-OPTIONS: SEL_2.
    SELECTION-SCREEN EXCLUDE IDS: 001.
    SELECTION-SCREEN END OF VERSION ABC.
    If the report attributes (or the attributes of the database program SAPDBldb ) contain the selection screen version ABC , the parameters PAR_1 and PAR_3 , the selection option SEL_2 and the comment with the text number 100 ( ID 001 ) are not displayed on the selection screen. When you maintain the attributes, the text symbol 008 of SAPDBldb is displayed if you press F4 on the field 'Selection screen version'.
    Variant 14
    SELECTION-SCREEN DYNAMIC SELECTIONS FOR TABLE dbtab.
    Addition
    ... ID id
    Effect
    This variant is allowed only in the database include program DBldbSEL . It informs you for which logical database tables additional selections are supported. If one of these tables is active in the report (i.e. it is declared under TABLES or lies somewhere on the path from the root of the database hierarchy to a table declared with TABLES ), a psuhbutton called 'Dynamic selections' appears on the selection screen. On pressing this button, the user branches to a dialog Taste where it is possible to enter selections for the fields of the relevant tables in the logical database. You can define the field list in two different ways:
    Via a selection view defined for the purpose:
    You can maintain selection views within the logical database maintenance transaction. They consist of a set of fields from logical database tables which are divided into groups. It is also possible to preselect fields. Customers can overlay these selection views with their own (i.e. in this case, the system searches first for the customer selection view and only accesses the SAP selektion view if no customer-specific view exists).
    If a preselection has already been made in the selection view, the user immediately sees the selection screen for the preselected fields and can enter selections. Otherwise, a fields must be selected first.
    Via all fields of all tables
    In this case, the user must first choose the tables and then select the fields for which additional selections are to be made before branching to the selection screen to enter the dynamic selections.
    The database access programm SAPDBldb then receives the WHERE clauses generated from the user entries in the form of a complex data object DYN_SEL .
    Addition
    ... ID id
    Effect
    Similar to the addition 2 ( SKIP ). This allows you to exclude tables from the possibility of dynamic selection via the selection screen versions.
    Note
    The exact definition of the object DYN_SEL is stored in the TYPE-POOL RSDS and is as follows:
    TYPES: BEGIN OF RSDS_WHERE,
             TABLENAME LIKE RSDSTABS-PRIM_TAB,
             WHERE_TAB LIKE RSDSWHERE OCCURS 5,
           END OF RSDS_WHERE.
    TYPES: BEGIN OF RSDS_TYPE,
             CLAUSES TYPE RSDS_WHERE OCCURS 5,
             TEXPR   TYPE RSDS_TEXPR,
             TRANGE  TYPE RSDS_TRANGE,
           END   OF RSDS_TYPE.
    DATA DYN_SEL TYPE RSDS_TYPE.
    The object DYN_SEL thus contains a component ( CLAUSES ) which is an internal table. Each line of this internal table contains a table name ( TABLENAME ) and another table ( WHERE_TAB ) which contains the WHERE clauses for the table ( TABLENAME ).
    You can find the structure of the other components in the type pool RSDS .
    TEXPR contains the selections in a format which allows storage and can be used for the "freely callable" function modules when entering dynamic selections ( FREE_SELECTIONS_INIT , FREE_SELECTIONS_DIALOG ). TRANGE contains the selections in the form of RANGES tables which can be used with the IN operator in SELECT , CHECK and IF .
    Note
    Neither the TYPE-POOL RSDS nor the declaration of DYN_SEL must appear in the database program. Both are automatically included by the system.
    In the database program SAPDBldb , an access to a table XXXX could look something like below:
    FORM PUT_XXXX.
      DATA L_DS_CLAUSES TYPE RSDS_WHERE.
      MOVE 'XXXX' TO L_DS_CLAUSES-TABLENAME.
      READ TABLE DYN_SEL-CLAUSES WITH KEY L_DS_CLAUSES-TABLENAME
                                 INTO L_DS_CLAUSES.
      SELECT * FROM XXXX
               WHERE field1 IN ...
               AND   field2 ....
               AND (L_DS_CLAUSES-WHERE_TAB).
          PUT XXXX.
      ENDSELECT.
    ENDFORM.
    Note
    If the table L_DS_CLAUSES-WHERE_TAB is empty, i.e. if no dynamic selections are entered for the table XXXX , the addition ... AND (L_DS_CLAUSES-WHERE_TAB) is ignored during the SELECT .
    Variant 15
    SELECTION-SCREEN FIELD SELECTION FOR TABLE dbtab.
    Addition
    ... ID id
    Effect
    This variant is allowed only in the database include program DBldbSEL . It informs you for which logical database tables field selection is supported.
    For these tables, you can fill just those database fields which the report actually needs. In the report, you determine these fields with GET dbtab FIELDS f1 ... fn or GET dbtab LATE FIELDS f1 ... fn (the field list is then supplemented by the key fields of the table dbtab ).
    By restricting to the really necessary field, you considerably improve performance. The database access program SAPDBldb receives the desired fields for the dynamic field selection in the form of an internal table SELECT_FIELDS .
    Note
    The exact definition of the object SELECT_FIELDS is stored in the TYPE-POOL RSFS and looks something like below:
    TYPES: BEGIN OF RSFS_TAB_FIELDS,
             TABLENAME LIKE RSDSTABS-PRIM_TAB,
             FIELDS LIKE RSFS_STRUC OCCURS 10,
           END OF RSFS_TAB_FIELDS.
    TYPES: RSFS_FIELDS TYPE RSFS_TAB_FIELDS OCCURS 10.
    DATA SELECT_FIELDS TYPE RSFS_FIELDS.
    SELECT_FIELDS is thus an internal table. Each line of this internal table contains a table name ( TABLENAME ) and another internal table ( FIELDS ) which contains the desired fields of the table ( TABLENAME ).
    Note
    Neither the TYPE-POOL RSFS nor the declaration of SELECT_FIELDS has to appear in the database program. Both are automatically included by the system. Unlike the objects connected with the addition DYNAMIC SELECTIONS , SELECT_FIELDS is also available in the report.
    In the database program SAPDBldb , an access to a table XXXX could look something like below:
    FORM PUT_XXXX.
      DATA L_TAB_FIELDS TYPE RSFS_TAB_FIELDS.
      MOVE 'XXXX' TO L_TAB_FIELDS-TABLENAME.
      READ TABLE SELECT_FIELDS WITH KEY L_TAB_FIELDS-TABLENAME
                               INTO L_TAB_FIELDS.
      SELECT (L_TAB_FIELDS-FIELDS)
                 INTO CORRESPONDING FIELDS OF XXXX
                 FROM XXXX
             WHERE field1 IN ...
             AND   field2 ....
          PUT XXXX.
      ENDSELECT.
    ENDFORM.
    Note
    If the table L_TAB_FIEDLS is empty, i.e. if no dynamic selections are entered for the table XXXX , SELECT (L_TAB_FIELDS) ... works like SELECT * ... , i.e. all fields of the table XXXX are filled.
    The internal table SELECT_FIELDS already contains values when the routine INIT is executed in the database program or when the INITIALIZATION processing is executed in the report. It can be manipulated by the appropriate program if it is absolutely necessary to fill another field for the logical database.
    Regards
    Sreeni

  • How to restrict more than one 1 range in select option on selection screen.

    Hi all,
    I have a requirement where I need to restrict user from giving more than 1 range for a date selct option ..other all features of multiple selection will be as usual...
    for eg we can do this if we disable / hide other cells if the user clicks on multiple ranges tab.. If only 1 cell is available to give the range user will not be able to give more than 1 range....
    I was thinking if I could use select_options_restrict but how do i fill its parameters...
    Can anyone send me the sample code or the same to achieve this functionality...I have used select_options_restrict to hide multiple ranges itself  ... But here user will be able to give range but only 1....
    Thanks and Regards
    Sweta

    HI,
    Please try the below logic.
    SELECT-OPTIONS: so_addr   FOR    ADR6-SMTP_ADDR NO INTERVALS.
    ***********remove_range_for_select_option******************* .
      DATA: ls_restrict  TYPE  SSCR_RESTRICT,    "The type for SELECT_OPTIONS_RESTRICT
            ls_opt_list  TYPE  SSCR_OPT_LIST,    "One list of options
            ls_asn       TYPE  SSCR_***.         "One line of table associating selection screen
                                                                      "object with opt. list
      CLEAR: ls_restrict,
             ls_opt_list,
             ls_asn.
    *Only EQ valid, discrete values, Include & Exclude
      ls_opt_list-name       = 'EQ'.
      ls_opt_list-options-eq = 'X'.
      APPEND ls_opt_list TO ls_RESTRICT-OPT_LIST_TAB.
      LS_ASN-KIND            = 'S'.
      LS_ASN-NAME            = 'SO_ADDR'.            "Select Option
      LS_ASN-SG_MAIN         = 'I'.
      LS_ASN-SG_ADDY         = '*'.
      LS_ASN-OP_MAIN         = 'EQ'.
      LS_ASN-OP_ADDY         = ' '.
      APPEND LS_ASN TO LS_RESTRICT-***_TAB.
    *Make use of SELECT-OPTIONS easier on the selection screen
      CALL FUNCTION 'SELECT_OPTIONS_RESTRICT'
        EXPORTING
          RESTRICTION            = LS_RESTRICT
        EXCEPTIONS
          TOO_LATE               = 1
          REPEATED               = 2
          SELOPT_WITHOUT_OPTIONS = 3
          SELOPT_WITHOUT_SIGNS   = 4
          INVALID_SIGN           = 5
          EMPTY_OPTION_LIST      = 6
          INVALID_KIND           = 7
          REPEATED_KIND_A        = 8
          OTHERS                 = 9.
      IF SY-SUBRC <> 0.
        MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
                WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    Edited by: Rajasekhar Reddy P on Mar 16, 2009 2:03 PM

  • Exclude one field from Logical Database's dynamic selection screen

    Hi Guru,
    I have a requirement to amend a program to exclude the document number field (bsik-belnr) from the dynamic selection-screen of the logical database KDF(Vendor Database) so that the program will not filter according to the document number.
    I have use the below syntax in my zprogram.
      selection-screen exclude select-options: doc-no.
    However I get syntax error "The addition EXCLUDE is only allowed in INCLUDE DBKDFSEL".
    Please advice.
    Best Regards,
    Fung

    The selection part of the logical database defines input fields for selecting data.
              The runtime environment displays these on the selection screen when you run an executable program linked to the logical database.
              Include called DB<ldbname>SEL.
            SELECTION-SCREEN BEGIN OF VERSION ver TEXT-xxx.
                                                                    SELECTION-SCREEN EXCLUDE ... .
                                                    SELECTION-SCREEN END OF VERSION ver.
    Defines a selection screen version (with a three-character name ver ). Between BEGIN OF VERSION and END OF VERSION , you can exclude selection screen objects for the version ver , i.e. remove them from the selection screen with SELECTION-SCREEN EXCLUDE.
              SELECTION-SCREEN DYNAMIC SELECTIONS FOR TABLE dbtab
    If one of these tables is active in the report (i.e. it is declared under TABLES or lies somewhere on the path from the root of the database hierarchy to a table declared with TABLES ), a pushbutton called 'Dynamic selections' appears on the selection screen.

  • How to disable the SELECT-OPTINS multiple selection screen's Ranges options

    Hi this is sekhar,
                      I have used the Select-options: statement with 'No-Interval' option. Now I need to restrict the user not to enter the values in the Ranges column of multiple selection screen. How can I do it....

    You can also refer this code as below : CHECK OUT SELECT OPTION sel_1_0.
    *& Report  ZTESTREP
    REPORT  ztestrep.
    Include type pool SSCR
    TYPE-POOLS sscr.
    Define the object to be passed to the RESTRICTION parameter
    DATA restrict TYPE sscr_restrict.
    Auxiliary objects for filling RESTRICT
    DATA opt_list TYPE sscr_opt_list.
    DATA ***      TYPE sscr_***.
    Define the selection screen objects
    First block: 3 SELECT-OPTIONS
    SELECTION-SCREEN BEGIN OF BLOCK block_0 WITH FRAME TITLE text-bl0.
    SELECT-OPTIONS sel_0_0 FOR sy-tvar0.
    SELECT-OPTIONS sel_0_1 FOR sy-tvar1.
    SELECT-OPTIONS sel_0_2 FOR sy-tvar2.
    SELECT-OPTIONS sel_0_3 FOR sy-tvar3.
    SELECTION-SCREEN END   OF BLOCK block_0.
    Second block: 2 SELECT-OPTIONS
    SELECTION-SCREEN BEGIN OF BLOCK block_1 WITH FRAME TITLE text-bl1.
    SELECT-OPTIONS sel_1_0 FOR sy-subrc.
    SELECT-OPTIONS sel_1_1 FOR sy-repid.
    SELECTION-SCREEN END   OF BLOCK block_1.
    INITIALIZATION.
    Define the option list
    ALL: All options allowed
      MOVE 'ALL'        TO opt_list-name.
      MOVE 'X' TO: opt_list-options-bt,
                   opt_list-options-cp,
                   opt_list-options-eq,
                   opt_list-options-ge,
                   opt_list-options-gt,
                   opt_list-options-le,
                   opt_list-options-lt,
                   opt_list-options-nb,
                   opt_list-options-ne,
                   opt_list-options-np.
      APPEND opt_list TO restrict-opt_list_tab.
    NOPATTERN: CP and NP not allowed
      CLEAR opt_list.
      MOVE 'NOPATTERN'  TO opt_list-name.
      MOVE 'X' TO: opt_list-options-bt,
                   opt_list-options-eq,
                   opt_list-options-ge,
                   opt_list-options-gt,
                   opt_list-options-le,
                   opt_list-options-lt,
                   opt_list-options-nb,
                   opt_list-options-ne.
      APPEND opt_list TO restrict-opt_list_tab.
    NOINTERVLS: BT and NB not allowed
      CLEAR opt_list.
      MOVE 'NOINTERVLS' TO opt_list-name.
      MOVE 'X' TO: opt_list-options-cp,
                   opt_list-options-eq,
                   opt_list-options-ge,
                   opt_list-options-gt,
                   opt_list-options-le,
                   opt_list-options-lt,
                   opt_list-options-ne,
                   opt_list-options-np.
      APPEND opt_list TO restrict-opt_list_tab.
    EQ_AND_CP: only EQ and CP allowed
      CLEAR opt_list.
      MOVE 'EQ_AND_CP'  TO opt_list-name.
      MOVE 'X' TO: opt_list-options-cp,
                   opt_list-options-eq.
      APPEND opt_list TO restrict-opt_list_tab.
    JUST_EQ: Only EQ allowed
      CLEAR opt_list.
      MOVE 'JUST_EQ' TO opt_list-name.
      MOVE 'X' TO opt_list-options-eq.
      APPEND opt_list TO restrict-opt_list_tab.
    Assign selection screen objects to option list and sign
    KIND = 'A': applies to all SELECT-OPTIONS
      MOVE: 'A'          TO ***-kind,
            '*'          TO ***-sg_main,
            'NOPATTERN'  TO ***-op_main,
            'NOINTERVLS' TO ***-op_addy.
      APPEND *** TO restrict-***_tab.
    KIND = 'B': applies to all SELECT-OPTIONS in block BLOCK_0,
                that is, SEL_0_0, SEL_0_1, SEL_0_2
      CLEAR ***.
      MOVE: 'B'          TO ***-kind,
            'BLOCK_0'    TO ***-name,
            'I'          TO ***-sg_main,
            '*'          TO ***-sg_addy,
            'NOINTERVLS' TO ***-op_main.
      APPEND *** TO restrict-***_tab.
    KIND = 'S': applies to SELECT-OPTION SEL-0-2
      CLEAR ***.
      MOVE: 'S'          TO ***-kind,
            'SEL_0_2'    TO ***-name,
            'I'          TO ***-sg_main,
            '*'          TO ***-sg_addy,
            'EQ_AND_CP'  TO ***-op_main,
            'ALL'        TO ***-op_addy.
      APPEND *** TO restrict-***_tab.
    KIND = 'S': Applies to SELECT-OPTION SEL_0_3
      CLEAR ***.
      MOVE: 'S'        TO ***-kind,
            'SEL_0_3'  TO ***-name,
            'I'        TO ***-sg_main,
            'N'        TO ***-sg_addy,
            'JUST_EQ'  TO ***-op_main.
      APPEND *** TO restrict-***_tab.
    Call function module
      CALL FUNCTION 'SELECT_OPTIONS_RESTRICT'
           EXPORTING
                 restriction                = restrict
              DB                          = ' '
           EXCEPTIONS
                 too_late                   = 1
                 repeated                   = 2
                 not_during_submit          = 3
                db_call_after_report_call  = 4
                selopt_without_options     = 5
                 selopt_without_signs       = 6
                 invalid_sign               = 7
                report_call_after_db_error = 8
                  empty_option_list          = 9
                 invalid_kind               = 10
                 repeated_kind_a            = 11
                 OTHERS                     = 12.

  • Problem in Submit via selection screen statement

    Dear Experts,
    I have designed selection screen and a dialog screen 100. I am passing the selection screen values to dialog screen using Selection screen via selection screen statement. When i tried to change the values in dialog screen, it is not allowing me to do so and the values are not refreshed.
    I have searched the SDN Forum, but not able to find the suitable thread.
    Regards,
    Ramesh Manoharan
    Edited by: ramesh.manoharan on Mar 17, 2010 1:03 PM

    Hi,
    I have used the below statement to pass values the values from selection screen to dialog screen (Created as an Executable program)
    Submit <pgm> via selection screen
      with ...... .
    Dialog screen is created as an executable program where i have created two subscreen area and populating the Selection Screen as subscreen by using the below statement:
    selection-screen begin of screen <subscreen no.> as subscreen.
    selection-screen end of screen <subscreen no.>.
    The problem i am facing is that the values of selection screen are getting populated in the dialog screen. But when i tried to change the input values in the dialog selection screen. I am unable to do that and it is not showing the new entered values. Only the previous values are shown (got from selection screen from Submit via selection screen statement).
    Kindly let me know where i am going wrong ? Kindly help me to overcome the problem .
    Regards,
    Ramesh Manoharan

  • If I do NOT use any event, except AT SELECTION SCREEN, Do I get any issues?

    Hi Experts,
    Pls. let me know that, If I do NOT use any event, except AT SELECTION SCREEN, Do I/prog. get any issues? (am also using AT SELECTION SCREEN OUTPUT for list box preperation).
    For some reason(execution of the report prog. with ENTER button), am using ONLY these 2 events.
    For full detials, pls. see my other thread with title,
    Is it possible to execute a REPORT prog. with pressing of ENTER button?
    thanq

    Hi
    srinivas see this program
    i am executing this program with out any event it is not showing any error but not giving output
    when i put start-of-selection then it is showing output
    *& Report  ZNNR_REPORT33
    REPORT  ZNNR_REPORT33 NO STANDARD PAGE HEADING MESSAGE-ID ZNNR LINE-SIZE 100 LINE-COUNT 65(4).
    ******DATA DECLARATIONS**********
    DATA : BEGIN OF IT_PLANT OCCURS 0,
            MATNR LIKE MARA-MATNR,
            WERKS LIKE MARC-WERKS,
            PSTAT LIKE MARC-PSTAT,
            EKGRP LIKE MARC-EKGRP,
           END OF IT_PLANT.
    DATA : BEGIN OF IT_PONO OCCURS 0,
            EBELN LIKE EKKO-EBELN,
            EBELP LIKE EKPO-EBELP,
            MATNR LIKE EKPO-MATNR,
            WERKS LIKE EKPO-WERKS,
            LGORT LIKE EKPO-LGORT,
           END OF IT_PONO.
    TABLES EKKO.
    ********END OF DATA DECLARATIONS*********
    ********SELECTION SCREEN DESIGN ***********
    SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.
    PARAMETER : P_WERKS LIKE MARC-WERKS MODIF ID S1.
    SELECT-OPTIONS : S_EBELN FOR EKKO-EBELN NO INTERVALS MODIF ID S2.
    SELECTION-SCREEN END OF BLOCK B1.
    SELECTION-SCREEN BEGIN OF BLOCK B2 WITH FRAME TITLE TEXT-004.
    SELECTION-SCREEN BEGIN OF LINE.
    PARAMETERS : R1 RADIOBUTTON GROUP G1 DEFAULT 'X' user-command uc1.
    SELECTION-SCREEN COMMENT 5(20) TEXT-002 FOR FIELD R1.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN BEGIN OF LINE.
    PARAMETERS : R2 RADIOBUTTON GROUP G1.
    SELECTION-SCREEN COMMENT 5(20) TEXT-003 FOR FIELD R2.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN END OF BLOCK B2.
    ******END OF SELECTION SCREEN DESIGN****************
    ***********SCREEN MODIFICATIONS*******************
    AT SELECTION-SCREEN OUTPUT.
      LOOP AT SCREEN.
        IF R1 EQ 'X' AND SCREEN-GROUP1 EQ 'S2'.
          SCREEN-INPUT = 0.
          MODIFY SCREEN.
        ENDIF.
        IF R2 EQ 'X' AND SCREEN-GROUP1 EQ 'S1'.
          SCREEN-INPUT = 0.
          MODIFY SCREEN.
        ENDIF.
      ENDLOOP.
    ********END OF SCREEN MODIFICATIONS*****************
    ***************SCREEN VALIDATIONS *****************
    at selection-screen.
      SELECT SINGLE *
               FROM EKKO
               INTO EKKO
               WHERE EBELN IN S_EBELN.
      IF SY-SUBRC <> 0.
        SET CURSOR FIELD 'S_EBELN-LOW'.
        MESSAGE E999 WITH TEXT-005.
        clear S_ebeln-low.
      ENDIF.
    ********end of screen validation*****************
      IF R1 EQ 'X'.
    *ULINE AT /1(48).
        WRITE : SY-VLINE ,2 'MATERIAL NUMBER',
                21 SY-VLINE , 22 'PLANT',
                27 SY-VLINE , 28 'STATUS',
                43 SY-VLINE , 44 'GRUP', 48 SY-VLINE.
        ULINE AT /1(48).
      ENDIF.
      IF R2 EQ 'X'.
        WRITE : SY-VLINE , 2 'PO NUMBER',
               12 SY-VLINE, 13 'ITEM',
               18 SY-VLINE,19 'MATERIAL NUMBER',
               37 SY-VLINE, 38 'PLANT',
               44 SY-VLINE, 45 'GRUP',
               49 SY-VLINE.
        ULINE AT /1(50).
      ENDIF.
    start-of-selection.
    *set pf-status '100'.
      IF R1 EQ 'X'.
        SELECT MATNR
               WERKS
               PSTAT
               EKGRP
           FROM MARC
           INTO TABLE IT_PLANT
           WHERE WERKS = P_WERKS.
        LOOP AT IT_PLANT.
          WRITE : SY-VLINE , 2 IT_PLANT-MATNR COLOR COL_KEY,
                 21 SY-VLINE , 22  IT_PLANT-WERKS COLOR COL_KEY,
                 27 SY-VLINE ,28 IT_PLANT-PSTAT COLOR COL_NORMAL,
                 43 SY-VLINE ,44 IT_PLANT-EKGRP COLOR COL_NORMAL.
        ENDLOOP.
      ENDIF.
      IF R2 EQ 'X'.
        SELECT EBELN EBELP MATNR WERKS LGORT
               FROM EKPO
               INTO TABLE IT_PONO
               WHERE EBELN IN S_EBELN.
        LOOP AT IT_PONO.
          WRITE : SY-VLINE , 2 IT_PONO-EBELN COLOR COL_KEY,
                 12 SY-VLINE , 13 IT_PONO-EBELP COLOR COL_KEY,
                 18 SY-VLINE , 19 IT_PONO-MATNR COLOR COL_NORMAL,
                 37 SY-VLINE , 38 IT_PONO-WERKS COLOR COL_NORMAL,
                 44 SY-VLINE , 45 IT_PONO-LGORT COLOR COL_NORMAL, 49 SY-VLINE..
        ENDLOOP.
      ENDIF.
      ULINE AT /1(50).
      WRITE :/10 'PAGE NUMBER', SY-PAGNO, '/' ,SY-PAGNO.
      ULINE AT /1(50).
      WRITE :/10 'PAGE NUMBER', SY-PAGNO.

  • How to make a dynamic selection screen

    Hi
    I have been searching the SDN for long time, but couldn't find the answer, so therefor a new post.
    I have an internal table with following values:
    VBKD-BSARK_E
    TVKO-VKORG
    By these values I would like to make a new selection-screen whith following:
    Parameters: FIELD1 like VBKD-BSARK_E.
    Parameters: FIELD2 like TVKO-VKORG.
    Next time the internal table can contain
    MARA-MATNR
    TVKO-VKORG
    VBAK-BSTZD
    And the parameters should then be:
    Parameters: FIELD1 like MARA-MATNR.
    Parameters: FIELD2 like TVKO-VKORG.
    Parameters: FIELD3 like VBAK-BSTZD.
    How do I do that -any suggestions?

    Hi,
    This piece of code will design selection screen based on radio button selection:
        SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-001 .
        SELECT-OPTIONS :  s_date  FOR  pnpbegps DEFAULT sy-datum  .   
        SELECTION-SCREEN: END OF BLOCK b1.
        SELECTION-SCREEN : BEGIN OF  BLOCK b2 WITH FRAME TITLE text-002.
        PARAMETERS:rb1 RADIOBUTTON GROUP rbf DEFAULT 'X'.
        PARAMETERS:rb2 RADIOBUTTON GROUP rbf .
        SELECTION-SCREEN: END OF BLOCK b2.
        SELECTION-SCREEN BEGIN OF BLOCK b3 WITH FRAME TITLE text-003 .
        SELECTION-SCREEN BEGIN OF LINE.
        SELECTION-SCREEN COMMENT 1(25) text-006 FOR FIELD px_pdf.
        PARAMETERS:  px_pdf AS CHECKBOX USER-COMMAND xxx  .      
        SELECTION-SCREEN END OF LINE.
        SELECTION-SCREEN BEGIN OF LINE.
        SELECTION-SCREEN COMMENT 1(15) text-004 FOR FIELD rb_app.
        PARAMETERS:rb_app RADIOBUTTON GROUP gbf DEFAULT 'X' USER-COMMAND uc01.
        PARAMETERS: p_file(128) MODIF ID 001.           " application server
        SELECTION-SCREEN END OF LINE.
    Thanks,
    Krishna..

  • Collective search on the Select-options field on the selection screen

    Hello experts,
                       I have a Y program and a selection screen for it. I have to get the BKPF-BELNR in the search help list. Since the table is too bulky to get all the documents form it. I thought I might need a condition of company code for fetching the documents. I have company code on the selection screen, but if I press F4, on the BELNR, my select-options internal table for <b>company code</b> is remains initial. I think for F4 events the values doesn't get populated in the internal tables, not sure.
                       Can you tell me, how to get the company code entered on the selection screen, on the F4 event. Or If this doesn't work, will collective search help solve my problem? If yes, Please let me know, which function module I can use to add a collective search to my select-options on the selection screen.
    Thanks,
    Ganesh Khumse.
    Points will be rewarded!

    Hi
    do like this
    TYPES : BEGIN OF ST_OBJID_SH,
             OTYPE TYPE HRP1000-OTYPE,
             OBJID TYPE HRP1000-OBJID,
            END OF ST_OBJID_SH.
    DATA : IT_OBJID_SH TYPE STANDARD TABLE OF ST_OBJID_SH.
    DATA : WA_OBJID_SH TYPE ST_OBJID_SH.
    ***********SELECTION SCREEN DESIGN***********************
    SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.
    *SELECT-OPTIONS : S_OTYPE FOR HRP1001-OTYPE NO INTERVALS .
    SELECT-OPTIONS : S_OBJID FOR HRP1001-OBJID NO INTERVALS .
    SELECT-OPTIONS : DATE FOR SY-DATUM NO-EXTENSION OBLIGATORY.
    SELECTION-SCREEN END OF BLOCK B1.
    **********END OF SELECTION SCREEN DESIGN*****************
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR S_OBJID-LOW.
    IF S_OBJID IS NOT INITIAL.
        SELECT OTYPE OBJID FROM HRP1000
                     INTO TABLE IT_OBJID_SH
                     WHERE OTYPE = 'D'.
    IF SY-SUBRC EQ 0.
    SEARCH HELP FOR QUALIFICATION.
        CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
          EXPORTING
                 DDIC_STRUCTURE         = ' '
            RETFIELD               =  'OBJID'
                 PVALKEY                = ' '
           DYNPPROG               = SY-REPID
           DYNPNR                 = SY-DYNNR
           DYNPROFIELD            = 'S_OBJID'
                 STEPL                  = 0
                 WINDOW_TITLE           =
                 VALUE                  = ' '
           VALUE_ORG              = 'S'
                 MULTIPLE_CHOICE        = ' '
                 DISPLAY                = ' '
                 CALLBACK_PROGRAM       = ' '
                 CALLBACK_FORM          = ' '
                 MARK_TAB               =
               IMPORTING
                 USER_RESET             =
          TABLES
            VALUE_TAB              =  IT_OBJID_SH
                 FIELD_TAB              =
                 RETURN_TAB             = RETURN_TAB
                 DYNPFLD_MAPPING        =
               EXCEPTIONS
                 PARAMETER_ERROR        = 1
                 NO_VALUES_FOUND        = 2
                 OTHERS                 = 3
        IF SY-SUBRC <> 0.
              MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
                      WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
        ENDIF.
      ENDIF.

  • Regarding selection screens in alv.

    Hi experts,
    SELECTION-SCREEN COMMENT 01(31) text-026 for field rastbis1.
    what is meant by this statement, and what is meant by 01(31) after comment.

    HI
    SELECTION-SCREEN COMMENT 01(31) text-026 for field rastbis1
    this statment means that
    for filed RASLBIS! put TEXT-026 as the comment at location starting at 01 loaction and up to 31 location
    after this statment for that filed from 01 location to 31 you can write any comment
    it will display on the screen
    see this example
    for radiobuttons normally the text will display before and next button
    i had changed that button first and text next like this
    REPORT  ZNNR_REPORT NO STANDARD PAGE HEADING MESSAGE-ID ZNNR LINE-SIZE 100 LINE-COUNT 65(4).
    ******DATA DECLARATIONS**********
    DATA : BEGIN OF IT_PLANT OCCURS 0,
            MATNR LIKE MARA-MATNR,
            WERKS LIKE MARC-WERKS,
            PSTAT LIKE MARC-PSTAT,
            EKGRP LIKE MARC-EKGRP,
           END OF IT_PLANT.
    DATA : BEGIN OF IT_PONO OCCURS 0,
            EBELN LIKE EKKO-EBELN,
            EBELP LIKE EKPO-EBELP,
            MATNR LIKE EKPO-MATNR,
            WERKS LIKE EKPO-WERKS,
            LGORT LIKE EKPO-LGORT,
           END OF IT_PONO.
    TABLES EKKO.
    ********END OF DATA DECLARATIONS*********
    ********SELECTION SCREEN DESIGN ***********
    SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.
    PARAMETER : P_WERKS LIKE MARC-WERKS MODIF ID S1.
    SELECT-OPTIONS : S_EBELN FOR EKKO-EBELN NO INTERVALS MODIF ID S2.
    SELECTION-SCREEN END OF BLOCK B1.
    SELECTION-SCREEN BEGIN OF BLOCK B2 WITH FRAME TITLE TEXT-004.
    SELECTION-SCREEN BEGIN OF LINE.
    <b>PARAMETERS : R1 RADIOBUTTON GROUP G1 DEFAULT 'X'.
    SELECTION-SCREEN COMMENT 5(20) TEXT-002 FOR FIELD R1.</b>
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN BEGIN OF LINE.
    <b>PARAMETERS : R2 RADIOBUTTON GROUP G1.
    SELECTION-SCREEN COMMENT 5(20) TEXT-003 FOR FIELD R2.</b>
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN END OF BLOCK B2.
    ******END OF SELECTION SCREEN DESIGN****************
    <b>Rewar dif usefull</b>

Maybe you are looking for