About parameters in selection screen

When it if select-option,when the value of low and high are initial,it will  select all the items,and if  the low and high value are not initial,it will select items in this range.
I just think if abap have this for a parameter ,like when it is initial,it will select all items,and when it is not initial,it will select the item which some field = this parameter.
thanks a lot!

Here you have to display the selct-option which will appear as a parameter on the selection screen and user can enter only one value as in a parameter.
select-options: s_para for mara-matnr no-extension
                                       no intervals.

Similar Messages

  • How to dynamically deactivate and activate parameters on selection screen?

    Hi,
    I need to deactivate/activate a parameter in my selection screen whenever i clicked on a particular radiobutton. I could deactivate the parameter when the screen is first loaded using the following code,
    <i>AT SELECTION SCREEN OUTPUT.
    LOOP AT SCREEN.
      IF SCREEN-NAME = 'P_DATE'.
         SCREEN-INPUT = '0'.
         MODIFY SCREEN.
      ENDIF.
    ENDLOOP.</i>
    But I have problems capturing the event when the user click on the radiobutton, so i could activate the parameter. I did not create any screen.
    Is there a way to solve this problem w/o creating a screen. If none, how do I go about it after I have created a screen for selection.
    Thanks for any suggestions.

    Hi CK,
    The following code might help,
    *-- Status of Screen Field (Ready/Not Ready for Input)
        fld_status   LIKE screen-input,
    PARAMETERS: rbut01  TYPE char01
                        RADIOBUTTON GROUP g1
                        USER-COMMAND ucomm1     "event for radio button click
                        DEFAULT 'X'.
                rbut02  TYPE char01
                        RADIOBUTTON GROUP btyp.
    Event Handler for Change of Budget Type *
    AT SELECTION-SCREEN.
    *-- In case user command is a budget type change (Radio Button Change)
      IF sscrfields-ucomm =  'UCOMM1'.
        IF rbut01 = 'X'.
          fld_status = '0'.
        ELSEIF rbut2 = 'X'.
          fld_status = '1'.
        ENDIF.
      ENDIF.
    At Selection Screen Output *
    AT SELECTION-SCREEN OUTPUT.
      LOOP AT SCREEN.
        CASE screen-name(4).
          WHEN 'FLD01' OR 'FLD02'.
    *---    Changing Status of Fld01 and Fld02 Fields on Change of Radio Button
            screen-input = fld_status.
            MODIFY SCREEN.
        ENDCASE.
      ENDLOOP.

  • How to use table field values as dynamic parameters on selection screen

    Hi,
    I need help on dynamic selection parameters.
    I need to display no. of parameters from the fields of a database table.
    Basically i want to pass field values of a table to selection screen and we can use those values as parameter on selection screen.
    If there are 10 entries in a table field( say field is field_name and entries are bukrs,kunnr etc.)
    I need to display as many parameters on screen as many values are there in field_name( In this case it is 10)
    SELECTION-SCREEN: BEGIN OF BLOCK b2 WITH FRAME TITLE text-t02.
    PARAMETERS:
                           p_bukrs(5) ,
                           p_kunnr(5) ,
    SELECTION-SCREEN END OF BLOCK b2.
    Thanx

    Hi,
    You can create it using Dynamic Program.Check this link below.
    [Creating Dynamic Programs|http://help.sap.com/saphelp_46c/helpdata/en/9f/db996135c111d1829f0000e829fbfe/content.htm]
    Hope this might help you.
    Thanks,
    Prashanth

  • Hi Experts, a question about messages in selection screen? thank you!

    Hi Experts,
    I have a selection screen and two parameters on it, I need to check if the entries exist if the fields is filled in, if it doesn't exist I need to issue a warning message, but if the two parameters are both filled in and the related entries both don't exist, how can I handle this situation? what I mean is that I want to display the two warnings at the same time(like below), now I only can display one warning, can anyone help me on this? thank you much!
    You are not authorised for this purchasing organisation
    Plant: invalid entry
    Purchasing organisation: invalid entry
    No valid record selected
    Kind regards
    Dawson

    Hi Dawson
    As far as i get from your disciption of the problem, i get that: -
    (a) You want to check that both the fields are filled or not
    (b) If they are filled, then you want to check if in database there exists any record pertaining to them.
    Correct me if i am wrong.
    If this is correct, then you will have to make use of nested if condtions to diaplay the warnings.
    Like as follows: -
    If pa1 IS INITIAL and pa2 IS INITIAL.
      <your warning message>.
    ELSEIF pa1 IS INITIAL and pa2 IS NOT INITIAL.
      <your warning message>.
    ELSEIF pa1 IS NOT INITIAL and pa2 IS INITIAL.
      <your warning message>.  
    ELSEIF pa1 IS NOT INITIAL and pa2 IS NOT INITIAL.
      <try matching it with the database records>.
      <your warning message>.
    ENDIF.
    As far as i know, the 2 warning messages cannot be issued as they appear in the status bar of the current screen. SO you will have to put them in if condition only and display the approriate warning .
    Hope this solves your problem.
    Regards
    Gaurav.

  • How to define f4 help for parameters in selection screen.

    Hi Folks,
    I have declared parametrs of type RLGRAP-FILENAME  and i want to select the path for the application server file by pressing f4 during run time , not like typing the path in the field input. Pls help me how to do that.
    Thanks in advance.
    Regards
    Rajesh

    Hai Rajesh
    DATA: I_FILETABLE TYPE FILETABLE,
          V_RC TYPE I.
    PARAMETERS: P_FILE LIKE RLGRAP-FILENAME.     "local file with contracts
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR P_FILE.
    CALL METHOD CL_GUI_FRONTEND_SERVICES=>FILE_OPEN_DIALOG
       EXPORTING
         WINDOW_TITLE            = 'Find File'
         DEFAULT_EXTENSION       = 'C:\'
         DEFAULT_FILENAME        = ''
         FILE_FILTER             = ',..'
       INITIAL_DIRECTORY       =
       MULTISELECTION          =
       WITH_ENCODING           =
      CHANGING
        FILE_TABLE               = I_FILETABLE
        RC                       = V_RC
       USER_ACTION             =
       FILE_ENCODING           =
      EXCEPTIONS
        FILE_OPEN_DIALOG_FAILED = 1
        CNTL_ERROR              = 2
        ERROR_NO_GUI            = 3
        NOT_SUPPORTED_BY_GUI    = 4
        others                  = 5
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
               WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    READ TABLE I_FILETABLE INTO P_FILE INDEX 1.
    Thanks & regards
    Sreenivasulu P

  • Hide the parameters on selection screen

    Hi1
    I have a report which has parameters as checkboxes in the sleection screen and by default all the three parameters are checked . What I want to do is hide these parameters in the selection screen while their functionality still existing mean when I run teh report the result should show what it showed when the three checjboxes were checked and the parameters were visible. So now I just want to hide these parameters in my selectiopn screen.
    Can anyone help me out pls.
    PARAMETERS:     p_varia TYPE disvariant-variant MEMORY ID wrk,
                    p_rb1 RADIOBUTTON GROUP G1  user-command ucomm default 'X' hide,
                    p_all AS CHECKBOX DEFAULT 'X' modif id 123,
                    p_group AS CHECKBOX modif id 123,
                    p_rb2 RADIOBUTTON GROUP G1,
                    p_date AS CHECKBOX MODIF ID 234,
                    p_bedat TYPE fpla-bedat DEFAULT sy-datum MODIF ID 234,
                    p_endat TYPE fpla-endat MODIF ID 234,
                    p_rental AS CHECKBOX MODIF ID 234.
    Thanks

    Hi,
    Try this sample code. Hope it will solve ur prob.
    REPORT  ztest_hl7.
    PARAMETERS: p_varia TYPE disvariant-variant MEMORY ID wrk,
    p_all AS CHECKBOX DEFAULT 'X' ,
    p_group AS CHECKBOX DEFAULT 'X' ,
    p_rental AS CHECKBOX DEFAULT 'X' .
    AT SELECTION-SCREEN OUTPUT.
      LOOP AT SCREEN.
        IF screen-name = 'P_ALL' OR screen-name = 'P_GROUP'
        OR screen-name = 'P_RENTAL'.
          screen-invisible = 1.
        ENDIF.
        MODIFY SCREEN.
      ENDLOOP.
    START-OF-SELECTION.
      WRITE /: p_all,p_group,p_rental.
    Regards,
    Joy.

  • Radio buttons & Parameters in Selection Screen...

    Hi all,
    I have a case in Selection Screen :
    There are 2 radio buttons(R1 & R2) and 4 parameters (P1, P2, P3, P4).
    WHen i select R1 then P1 and P2 should become mandatory
    when i select R2 then P1, P2, P3 & P4 should become mandatory.
    I have coded it using LOOP AT SCREEN ...
    So, by default R1 will be selected then P1, P2 will become mandatory. Now when i select R2, it gives an status message as 'FILL IN THE REQUIRED FIELDS' .....So how can i overcome this and be able to select R2 which enables P1, P2, P3,P4 as mandatory ?
    Please provide some feasible solution. Thanks!

    Hi Jayati,
    Below is the code...i have used.
    parameters : R1 radiobutton group rad modif id RAD user-command com,
    R2 radiobutton group rad modif id RAD.
    parameters : p1 type char10 modif id grp ,
    p2 type char10 modif id grp ,
    p3 type char10 modif id gr2,
    p4 type char10 modif id gr2.
    INITIALIZATION.
    r1 = 'X'.
    At selection-screen output.
    if R1 = 'X'.
    loop at screen.
    if screen-group1 = 'GRP'.
    screen-required = '1'.
    modify screen.
    endif.
    if screen-group1 = 'GR2'.
    screen-required = '0'.
    modify screen.
    endif.
    endloop.
    else.
    loop at screen.
    if screen-group1 = 'GRP'.
    screen-required = '1'.
    modify screen.
    endif.
    if screen-group1 = 'GR2'.
    screen-required = '1'.
    modify screen.
    endif.
    endloop.
    endif.
    Now while we execute this....R1 is selected by default...which enables P1 & P2 as mandatory. okay ? ...Now when i select R2 at this point of time. it says 'FILL IN ALL REQUIRED ENTRY FIELDS'. (and it shows only P1 & P2 as mandatory).
    But the user don't want to fill P1 & P2. ...(just for selecting R2)..
    Instead he wants R2 to get selected with the below
          a) Without entering values for P1 & P2
          b) WIthoug displaying any Error Meassage as 'FILL IN ALL REQUIRED ENTRY FIELDS'.
          c) P1 P2 P3 P4 should become mandatory
    Hope u understood it now.

  • Hi, experts, a question about fields in selection screen?

    Hi Experts,
    In my selection screen there are two fields, one is customer nr(kunnr), another is a checkbox, and I want to know is that when the customer is filled in and the checkbox is marked and then I press "enter", there should be a email address of the customer displayed at the right of the checkbox, thank you in advance.
    by the way, I have known how to get the email address but I don't know how to make the email address display at the right of the checkbox.
    Kind regards
    Dawson
    Edited by: dawson wang on Mar 28, 2009 4:49 AM

    Hi,
    Test Sample Code Bellow it will solve out your problem. First enter the pernr and than click the Check Box.
    TABLES: pa0001.
    SELECTION-SCREEN BEGIN OF LINE.
    SELECTION-SCREEN COMMENT 1(30) tpernr.
    PARAMETERS: ppernr LIKE pa0001-pernr.
    SELECTION-SCREEN COMMENT 42(1) t.
    PARAMETERS: check AS CHECKBOX USER-COMMAND a.
    SELECTION-SCREEN COMMENT 46(50) cpernr FOR FIELD ppernr MODIF ID dpt.
    SELECTION-SCREEN END OF LINE.
    INITIALIZATION.
    tpernr = 'Please Enter Pernr'.
    AT SELECTION-SCREEN OUTPUT.
      IF check = 'X'.
        PERFORM get_lables.
        LOOP AT SCREEN.
          IF screen-group1 = 'DPT'.
            screen-intensified = '1'.
            MODIFY SCREEN.
          ENDIF.
        ENDLOOP.
      ELSE.
        CLEAR: cpernr.
      ENDIF.
    **&      Form  get_lables
    **       text
    FORM get_lables.
      IF ppernr IS INITIAL.
        cpernr = ''.
      ELSE.
        SELECT SINGLE * FROM pa0001
          WHERE pernr = ppernr
            AND endda = '99991231'.
        IF sy-subrc = 0 .
          cpernr = pa0001-ename.
        ENDIF.
      ENDIF.
    ENDFORM.                    "get_lables
    Please Reply if any Issue,
    Best Regards,
    Faisal

  • Parameters in Selection Screen

    Hi All,
    I want to display input box just after radiobutton.
    if I am doing like this:
    SELECTION-SCREEN BEGIN OF BLOCK s4 WITH FRAME TITLE text-004 .
    PARAMETERS: p_r4 RADIOBUTTON GROUP rad2 DEFAULT 'X',
                p_r5 RADIOBUTTON GROUP rad2, p type c ,p5(5) type c.
    SELECTION-SCREEN END OF BLOCK s4.
    then the input box is displayed below radiobutton, but I want it just after radio button.
    Can anyone help me in this...

    Hi,
    DATA: L_AGES TYPE C.
    DATA: L_AGES1(5) TYPE C.
    SELECTION-SCREEN BEGIN OF BLOCK CPRF WITH FRAME TITLE TEXT-PRF.
    SELECTION-SCREEN BEGIN OF LINE.
    SELECTION-SCREEN COMMENT 1(10) TEXT-001 FOR FIELD P.
    SELECT-OPTIONS: P FOR L_AGES NO-EXTENSION NO INTERVALS.
    SELECTION-SCREEN COMMENT 25(3) TEXT-002 FOR FIELD P_RBPRF1.
    SELECTION-SCREEN POSITION 28.
    PARAMETERS: P_RBPRF1 RADIOBUTTON GROUP R2.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN BEGIN OF LINE.
    SELECTION-SCREEN COMMENT 1(10) TEXT-003 FOR FIELD P1.
    SELECT-OPTIONS: P1 FOR L_AGES1 NO-EXTENSION NO INTERVALS.
    SELECTION-SCREEN COMMENT 25(3) TEXT-004 FOR FIELD P_RBPRF2.
    SELECTION-SCREEN POSITION 28.
    PARAMETERS: P_RBPRF2 RADIOBUTTON GROUP R2.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN END OF BLOCK CPRF.

  • How to validate parameters on selection-screen

    Dear All,
    In my selection-screen I have Material Document No. and Material Number as parameters and I wish to validate Material No. on the basis of Material Document i.e the user should be able to input only those material nos. that belong to the material document no. to be inputted by the user. The code of my selection-screen looks like following:
    PARAMETERS: P_MBLNR LIKE MSEG-MBLNR,
                P_MATNR LIKE MSEG-MATNR,
                P_GJAHR LIKE MSEG-GJAHR,
                P_MENGE LIKE MSEG-MENGE,
                Q_MENGE LIKE MSEG-MENGE,
                P_SGTXT LIKE MSEG-SGTXT.
    Please suggest a solution.
    Regards,
    Alok.

    Hi,
    As much as I understand u want a validation for the data for field2 from the values in field1.
    If So,Please go throuhg the code below.
    REPORT ZSM_TEST.
    TABLES : MARA.
    SELECTION-SCREEN BEGIN OF BLOCK B1.
    PARAMETERS : S_MTART LIKE MARA-MTART OBLIGATORY.
    PARAMETERS : S_MATNR LIKE MARA-MATNR OBLIGATORY MODIF ID M1.
    SELECTION-SCREEN END OF BLOCK B1.
    To Disable the field2(Material Code) in case the Material Type is not entered
    AT SELECTION-SCREEN OUTPUT.
    LOOP AT SCREEN.
    IF SCREEN-GROUP1 EQ 'M1'.
    IF S_MTART IS INITIAL.
    SCREEN-INPUT = '0'.
    ELSE.
    SCREEN-INPUT = '1'.
    ENDIF.
    MODIFY SCREEN.
    ENDIF.
    ENDLOOP.
    Check the data for combibation of field1 and field2
    AT SELECTION-SCREEN.
    CHECK S_MTART IS NOT INITIAL AND
    S_MATNR IS NOT INITIAL.
    SELECT SINGLE * FROM MARA
    WHERE MTART EQ S_MTART
    AND MATNR EQ S_MATNR.
    IF SY-SUBRC NE 0.
    MESSAGE E002(SY) WITH 'Invalid Material & Type Combination!!'.
    ENDIF.
    START-OF-SELECTION.
    WRITE : 'BINGO'.

  • Enable parameters on selection screen

    Hi,
    Can you please give your suggestions for following requirement..
    I have 4 parameters ( p1 p2 p3 p4) on selection screen..
    But i need to enable only 2 parameters ( p3 p4) to enter selection criteria on selection screen..
    p1 p2 should not take entries ..
    Your suggestions are helpfull..
    Thanks,
    Parnith..

    then use this
    PARAMETERS:
      p1        TYPE c,
      p2        TYPE c,
      p3        TYPE c,
      p4        TYPE c.
    AT SELECTION-SCREEN OUTPUT.
      LOOP AT SCREEN.
        CASE sy-sysid.
          WHEN 'P111'.
            CASE screen-name.
              WHEN 'P1'.
                screen-input = 0.
                MODIFY SCREEN.
              WHEN 'P2'.
              WHEN 'P3'.
              WHEN 'P4'.
            ENDCASE.
          WHEN 'P222'.
            CASE screen-name.
              WHEN 'P1'.
              WHEN 'P2'.
                screen-input = 0.
                MODIFY SCREEN.
              WHEN 'P3'.
              WHEN 'P4'.
            ENDCASE.
          WHEN 'P333'.
            CASE screen-name.
              WHEN 'P1'.
              WHEN 'P2'.
              WHEN 'P3'.
                screen-input = 0.
                MODIFY SCREEN.
              WHEN 'P4'.
            ENDCASE.
          WHEN 'P444'.
            CASE screen-name.
              WHEN 'P1'.
              WHEN 'P2'.
              WHEN 'P3'.
              WHEN 'P4'.
                screen-input = 0.
                MODIFY SCREEN.
            ENDCASE.
        ENDCASE.
      ENDLOOP.

  • Alv for parameters on selection screen

    hi friends,
    what i need is some sample of an selection screen with an alv where i can add lines ( e.g. for fields ) to and the information is then stored to internal table so that it can be used for further steps...how could i do that the best way ? any ideas ?
    Clemens

    Hi,
    Check the program "BCALV_EDIT_01"
    there is an option of CREATE entries which can be used to create a record which is captured in the internal table for further processing.
    Cheers
    VJ

  • Clear parameters at a selection screen

    Hi
    I've a report with three parameters, but when i change one of them the value of last doesn't desappear. I try with clean [others values of parameters], but doesn't work.
    Can help me ?
    Thanks

    Hi,
    Try to clean the parameters in Selection-Screen Events.
    AT SELECTION_SCREEN.
    AT SELECTION_SCREEN OUTPUT.
    Apart from selection screen events parameters wont change.
    Hope this resolves your issue.
    Esle,Copy & Paste your codes.
    Regards,
    Gurpreet

  • Get selection screen parameters from sap query

    Hello. I use SAP Query Reporting, so I added a report assignment for detailing (sq01 ->  Change button -> Goto -> Report Assignment -> Insert row -> Other type row -> Abap Report Program)
    and put there ABAP program.
    When I run query and press CtrlShiftF1  (or double click) It calls my abap program.
    So the question is: how to get selection screen parameters in my program ?
    to be more precise I want to get date parameter (begda, endda)
    Thanks a lot.

    There is a Z query which I can see in sq01. I set reporting period and run the query; when I run it, it gives me the employee list.
    So I wrote the abap report to get an employee details, customized query as I mentioned above.
    The query calls my report and I need to get parameters.
    SELECTION-SCREEN BEGIN OF BLOCK frm1 WITH FRAME TITLE text-001.
    PARAMETER :  p_pernr LIKE p0001-pernr OBLIGATORY MATCHCODE OBJECT prem.
    PARAMETER : p_date LIKE sy-datum.
    SELECTION-SCREEN END OF BLOCK frm1.
    Parameter
    p_pernr
    passes normal. ALV Query contains it, but I'd like to get one more parameter from selection screen of the query and don't know how to get it.

  • How can I get selection screen values from outside of program?

    Hi. all.
    Now. I'm developing moritoring systems and I have problems. for getting selection screen values in runtime. Is there any function, methods or structure to know this?
    I'd like to get selection screen values while several programs working in runtime and update these values to table to show current system's status and input values for users in real time.
    For example.
    Now. 3 PGMs are working on systems.
    each PGM is ZAAA01, ZAAA02, ZAAA03.
    and ZAAA01 needs input parameter P01, ZAAA02 needs input parameter P02, ZAAA03 needs input parameter P03.
    In this case, I have to know values of P01, P02 and P03.
    The mornitoring systems will show current working status of PGMs(ZAAA01~03)' and these PGMs' input values.
    As fas as I know, the structure 'SCREEN' can be used in each PGM for runtime. Is there any SAP system structure or something else for this purpose?
    I hope your hopeful repsponse.
    Thanks.

    Umm..I need to explain more about this.
    of course I know  SET, GET PARAMETERS.
    But I'd like to minimize coding for each PGM level.
    I have over hundreds PGMs and I have to develop the PGM(including tables and structures) that mornitor
    all of those PGMs on a report in real-time.
    This PGM is kind of  Process Manager.
    First I should know dialogue job PGM and background job that pass parameters using SAP(ABAP) Memory.
    And then I have to update those PGMs' input values via screens into tables in real-time.
    So, I couldn't use SET,GET PARAMETERS for this PGM.
    I want to know methods that can be used for getting information about runtime PGMs' selection screen field values in SAP systems wide.
    Please help me some one knows this.

Maybe you are looking for

  • 24" Imac Overheating HD (?)

    Hello (specs of machine in question will follow below). I saw someone with a similar problem's post in the archives, but there was no resolution listed so I'm hoping for some direction/help from the community. A few weeks ago I was playing a video ga

  • What are the benefits to having more than 1GB RAM?

    I notice the repeated advice in this forum over the question of "Should I get a Matched pair of 2 x 512MB or total 1.5GB RAM in my iMac G5 Rev. A/B?", and the answer always seems to be "more RAM will always perform faster." Oh yeah, why? Someone poin

  • SQL Server 2008 Express edition install issue.

    Ok, i've been looking around forums for a while now and have not found a post similar to this one or one that offers a solution; so here it goes. I'm trying to install management studio and in the web platform installer i keep getting this error: "Yo

  • Board rated wattage running a cpu at the upper limit

    Whether it be Athlon II's or Phenom II's for AM3 MSI board ( have the MSI i 880gm-e41  ) the lower end of running temp availability of cpus for purchase is 95w.  Earlier I saw where the advice was to not run 125 w. etc cpus above the board's recommen

  • Finder does not show flash drive but it is mounted.

    After reformatting a drive to FAT it was automounted to the /Volumes directory. I checked and it is there with all of the content there. Disk Utility also is telling me that it was mounted. The weird part is that the Finder does not have the drive in