How to assing parameters to select-options

hi all
thanks in advance
how to assign parameter value to select-option
date
SELECTION-SCREEN: BEGIN OF BLOCK B1 WITH FRAME TITLE text-001.
  select-options    s_budat     FOR mkpf-budat  OBLIGATORY,
                          s_budat1     FOR mkpf-budat.
   parameters cperiod like mkpf-budat.
  SELECTION-SCREEN:END OF BLOCK B1.
cperiod assign to s_budat-low
  or dummy s_budat1  and how give selection criteria
thanks all

Hi,
I think you want to set some default values in select options.
so following is code...
TABLES:MKPF.
SELECTION-SCREEN: BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.
SELECT-OPTIONS: S_BUDAT FOR MKPF-BUDAT OBLIGATORY,
                S_BUDAT1 FOR MKPF-BUDAT.
PARAMETERS CPERIOD LIKE MKPF-BUDAT.
SELECTION-SCREEN:END OF BLOCK B1.
AT SELECTION-SCREEN OUTPUT.
  S_BUDAT-LOW = SY-DATUM.
  append s_budat.
hope it will help you...
Award points if useful...

Similar Messages

  • How to use offset for select-option parameter ?

    Hi experts
    could anybody please let me know how to use offset for select-option parameter. i can able to use offset for table fields, variabiles and all , but don't know how to use for parameters.
    following is my code
    SELECT-OPTIONS: s_prctr  FOR vbsegs-prctr OBLIGATORY.
    here "prctr"  length is 10.
    i'm using two tables  1. vbsegd-bupla
                                    2. vbsegs-prctr
    here prctr+6(4) = bupla.
    "Bupla" length is 4
    SELECT belnr gjahr bukrs bupla sgtxt buzei FROM vbsegd INTO CORRESPONDING FIELDS OF TABLE it_vbsegd FOR ALL ENTRIES IN it_vbkpf
                                                                 WHERE belnr = it_vbkpf-belnr
                                                                   AND gjahr = it_vbkpf-gjahr
                                                                   AND bukrs = it_vbkpf-bukrs
                                                                   AND bupla IN s_prctr.  
    the above statement is not working as prctr and bupla lenths are different. here i want to use offset.
    SELECT belnr gjahr bukrs prctr sgtxt buzei FROM vbsegs INTO CORRESPONDING FIELDS OF TABLE it_vbsegs FOR ALL ENTRIES IN it_vbkpf
                                                                WHERE belnr = it_vbkpf-belnr
                                                                  AND gjahr = it_vbkpf-gjahr
                                                                  AND bukrs = it_vbkpf-bukrs
                                                                  AND prctr IN s_prctr.
    this is working as prctr and s_prctr lengths are equal.
    could anybody please help me out in this.
    Thanks in advance.
    regards
    satish

    Below code will work for you.
    SELECT-OPTIONS: s_prctr  FOR vbsegs-prctr OBLIGATORY.
    RANGES: s_bupla FOR vbsegd-bupla.
    s_bupla[] = s_prctr[].
    DELETE ADJACENT DUPLICATES FROM s_bupla.
    SELECT belnr gjahr bukrs bupla sgtxt buzei FROM vbsegd INTO CORRESPONDING FIELDS OF TABLE it_vbsegd FOR ALL ENTRIES IN it_vbkpf
                                                                  WHERE belnr = it_vbkpf-belnr
                                                                    AND gjahr = it_vbkpf-gjahr
                                                                    AND bukrs = it_vbkpf-bukrs
                                                                    AND bupla IN s_bupla.

  • How to pass values to select options of custom transactions?

    I have to call custom transaction-ZMM_POST  from my custom report.
    I have to pass values to select options(Not to parameters) of ZMM_POST  from my report only.
    Please tell me how to pass values to select options of custom transactions?

    Have you tried this?
    DATA: T_RSPARAMS TYPE STANDARD TABLE OF RSPARAMS WITH HEADER LINE.
    T_RSPARAMS-SELNAME = "S_BUKRS".
    T_RSPARAMS-KIND = "S".
    T_RSPARAMS-SIGN = "I".
    T_RSPARAMS-OPTION = "BT".
    T_RSPARAMS-LOW = "100".
    T_RSPARAMS-HIGH = "300"
    APPEND T_RSPARAMS.
    SUBMIT Z_DUMMY WITH SELECTION-TABLE  T_RSPARAMS.
    Greetings,
    Blag.

  • How can we pass the select-option value to modulepool program?

    hi,
      how can we pass the select-option value to modulepool program ?
      Because if i declared select-options in executable program and i used SSCRFIELDS to define push buttons in selection screen.
               My requirement if enter the values to select-options and press UPDATE pussbotton then i want call screen which contains tablecontrol.
               How i get select-option values to PAI of call screen for getting the data from database table to my internal table?

    Oh I thought that you have selection-screen and again you are working on dialog programming.
    if you want to use select-option directly in module pool then it is not possible.
    but you can do other way.
    create two varaiables
    data : v_kun_low like kna1-kunnr,
             v_kun_high like kna1-kunnr.
    use these two variables in layout ,let user knows that he can not give options like gt,lt,eq ,it will be always BT.
    and also when you see normal report program,you can use multiple values in either low or high,but here it is not possibel.
    use can enter only low value and high value.
    when you come to program point of view
    declare one range
    ranges r_kunnr for kna1-kunnr.
    do the coding like
    r_kunnr-low = v_kun_low.
    r_kunnr-high = v_kun_high.
    r_kunnr-options = 'BT'.
    r_kunnr-sign = 'I'.
    append r_kunnr.
    now you can use r_kunnr in select query ,it will work like select-option.
    other than this there is no option.
    Thanks
    Seshu

  • Parameters and Select Option in ABAP OO

    Hi all,
    it's possible to build an application starts with a method of a class thats declares parameters and select-option or I have to do it custom creating a dynpro and some input field as parameters?
    thanks
    enzo

    Just to add detail: the function module RS_REFRESH_FROM_SELECTOPTIONS returns a table of TYPE RSPARAMS_TT.
    The structure of this table is:
    SELNAME
    RSSCR_NAME
    KIND
    RSSCR_KIND
    SIGN
    TVARV_SIGN
    OPTION
    TVARV_OPTI
    LOW
    TVARV_VAL
    HIGH
    TVARV_VAL
    the first field is the name of the selection parameter, the others have the same structure obtained declaring a range with:
    TYPES|DATA <rangetab> TYPE RANGE OF <type>.
    see the help topic http://help.sap.com/saphelp_470/helpdata/en/9f/dba71f35c111d1829f0000e829fbfe/content.htm

  • How to do validations for select-options

    Hi gurus,
    can you suggest me
    how to do validations for select-options
    Thanks&ragards,
    Kals.

    HI,
    TABLES: BKPF.
    TYPES: BEGIN OF TY_BKPF,
           BUKRS TYPE BUKRS,   "COMPANY CODE
           GJAHR TYPE GJAHR,   "FISCAL YEAR
           MONAT TYPE MONAT,   "FISCAL PERIOD
    DATA: T_BKPF TYPE TABLE OF TY_BKPF,
          W_BKPF TYPE TY_BKPF.
    SELECTION-SCREEN : BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.
    SELECT-OPTIONS: S_CODE   FOR BKPF-BUKRS,
                    S_YEAR   FOR BKPF-GJAHR,
                    S_PERIOD FOR BKPF-MONAT.
    SELECTION-SCREEN: END OF BLOCK B1.
                        AT SELECTION-SCREEN                           *
    IF S_CODE IS INITIAL OR S_YEAR IS INITIAL OR S_PERIOD IS INITIAL.
      MESSAGE E000(0) WITH 'ENTER VLAUES'.
    ENDIF.
    SELECT SINGLE * FROM BKPF WHERE BUKRS IN S_CODE.
      IF SY-SUBRC <> 0.
      MESSAGE E000(0) WITH 'ENTER VALID VALUES'.
      ENDIF.
    reward if useful
    thanks and regards

  • How to set the parameter selection *optional* for each subreport?

    Hi,
    I am using Crystal Reprots 11.
    I create 10 subreports, and each subreport contains a Parameters Field.
    The 10 subreports are put in 10 footer sections in increasing order, i.e. subreport1, subreport2, subreport3, ..., subreport10.
    When I use "Print Preview" to take a look at the whole report, CR prompts a "Edit Values" window for selecting parameter values for all 10 subreports.
    For example, if I only select parameter values for subreport1 and click "OK", 9 error messages on the "Edit Values" window come out above the selection list box of every other subreports (i.e. subreport2 ~ subreport10) showing that: 'The value is not valid'.
    Sometimes, I just want to review some specific subreports but not all.
    How should I do to set the parameter selection optional (not mandatory) for each subreport?
    Thank you in adavance.
    Edited by: Holdup on Feb 17, 2012 3:44 PM

    Hi,
    Here's how you can make the prompts optional (Assuming you're using CR 2008 or higher):
    1) Go into each subreport
    2) You should see the parameter in the Field Explorer. Right-click the name and select Edit > Look for an option called 'Optional Prompt'. Set it to true
    3) If you have a record selection in the subreport, then you need to modify the selection formula to something like this:
    if not(hasvalue({?Parameter_Name})) then True else = {?Parameter_Name}
    Hope this helps!
    -Abhilash

  • How to add OBLIGATORY for SELECT-OPTIONS

    Hi experts,
    I can use OBLIGATORY for PARAMETERS
    PARAMETERS :s_WMno  TYPE LINK-LGNUM DEFAULT 'SCA' OBLIGATORY.
    I want to add OBLIGATORY for SELECT-OPTIONS. How to do this?
    SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME .
        SELECT-OPTIONS:  s_matnr FOR mara-matnr .
    SELECTION-SCREEN END OF BLOCK b1.
    Many thanks.

    Hi,
    TABLES spfli.
    SELECT-OPTIONS : carrid FOR spfli-carrid OBLIGATORY. " This makes only Low field Obligatory
    AT SELECTION-SCREEN OUTPUT.
      LOOP AT SCREEN.
        IF screen-name = 'CARRID-HIGH'. " To make High field also obligatory
          screen-required = 1.
          MODIFY SCREEN.
        ENDIF.
      ENDLOOP.
    Cheerz
    Ram

  • How to fill empty parameter (selection-option)

    Hi!
    On selection screen I have two parameters (s_egrid and s_empid). If user enter something in first (but not in second) one, second one should be filled from database.
    The problem is that I don't know how to fill the empty parameter.
    Let's say that i have an internal table i_zemployee with list of all necessary employee Id's (stored in field empid)
    if I Ioop like this
    loop at i_zemployee into wa_zemployee.
        insert wa_zemployee-empid into s_empid.
      endloop.
    ... I did something stupid but i hope that you understand what i need:
    s_emipd[1] = 'u1'.
    s_emipd[2] = 'u7'.
    s_emipd[3] = 'u9'.
    ... like array of user id's.
    and this s_empid I need in my next SELECT statement like
    SELECT * FROM ...
        WHERE empid in s_empid.
    if someone knows the solution thanks in advance!
    T.

    HI try something like this...
    tables: mara, makt.
    data: begin of itab occurs 0,
    matnr like mara-matnr,
    end of itab.
    data : begin of btab occurs 0,
    maktx like makt-maktx,
    end of btab.
    ata mak like makt-maktx.
    DATA : return like ddshretval occurs 0 with header line.
      data: begin of dynpfields occurs 3.
              include structure dynpread.
      data: end of dynpfields.
    select-options: p_matnr for mara-matnr.
    select matnr from mara into table itab where matnr IN p_matnr.
    loop at itab.
    write: / itab-matnr.
    endloop.
    Initialization.
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_matnr.
    REFRESH ITAB.
    SELECT matnr FROM mara INTO TABLE ITAB.
    call function 'F4IF_INT_TABLE_VALUE_REQUEST'
    EXPORTING
    retfield = 'MATNR '
    dynprofield = 'P_MATNR '
    dynpprog = sy-REPID
    dynpnr = sy-dynnr
    value_org = 'S'
    TABLES
    value_tab = ITAB
    return_tab = return.
    select single maktx from makt into  mak where matnr = return-fieldval.
    p_matnr = return-fieldval.
    refresh return.
    clear return.
    move 'P_MAKTX' to dynpfields-fieldname.
    move mak to dynpfields-fieldvalue.
    append dynpfields.
    CALL FUNCTION 'DYNP_VALUES_UPDATE'
      EXPORTING
        dyname                     = 'SY-REPID'
        dynumb                     = '1000'
      tables
        dynpfields                 = dynpfields
    IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    refresh return.
    clear return.
    validate according to ur requirement.
    Regards
    Syed A

  • How to pass value to select-option parameter using SET PARAMETER Command

    Hi,
        Am passing values to selection-screen fields in report RV13A004 ( used in VK11, VK12 and VK13). using below statement but material number is select-option in this report. am able to pass  MATERIAL FROM using SET PARAMETER ID, can i know how to pass values MATERIAL TO range in select-options fields using SET PARAMETER Command ??
    Passing values to parameter id
    set parameter id 'VKS' field kschl.
    set parameter id 'VKO' field vkorg.
    set parameter id 'VTW' field vtweg.
    set parameter id 'KDA' field erdat.
    set parameter id 'MAT' field matnr_from.
    Change condition price.
    call transaction 'VK12' and skip first screen.
    Thanks in advance.
    Regards,
    Balamurugan.

    Hi,
    instead of using set parameters and dden call transaction use this..........
    submit RV13A004  WITH SELECTION-TABLE rspar
    Effect
    If you specify this addition, parameters and selection criteria on the selection screen are supplied from an internal table rspar. You must specify an internal table with the row type RSPARAMS for rspar. The structured data type RSPARAMS is defined in the ABAP Dictionary and has the following components, all of which are data type CHAR:
    SELNAME (length 8),
    KIND (length 1),
    SIGN (length 1),
    OPTION (length 2),
    LOW (length 45),
    HIGH (length 45).
    To supply parameters and selection criteria for the selection screen with specific values, the lines in the internal table rspar must contain the following values:
    SELNAME must contain the name of a parameter or selection criterion for the selection screen in block capitals
    KIND must contain the type of selection screen component (P for parameters, S for selection criteria)
    SIGN, OPTION, LOW, and HIGH must contain the values specified for the selection table columns that have the same names as the selection criteria; in the case of parameters, the value must be specified in LOW and all other components are ignored.
    If the name of a selection criterion is repeated in rspar, this defines a selection table containing several lines and passes it on to the selection criterion. If parameter names occur several times, the last value is passed on to the parameter.
    The contents of the parameters or selection tables for the current program can be entered in the table by the function module RS_REFRESH_FROM_SELECTOPTIONS.
    Notes
    In contrast to selection tables, the data types of the components LOW and HIGH in table rspar are always of type CHAR and are converted to the type of the parameter or selection criterion during transfer, if necessary.
    When entering values, you must ensure that these are entered in the internal format of the ABAP values, and not in the output format of the screen display.
    Cheers
    Will.

  • How to read data from select Options in another view without using context

    I have 2 views, one for selection screen and another for displaying result.
    In selection screen view I have define a select options with the help of webdynpro component.
    Now my object is display result in result view based on entry of selection screen.
    I don't want to do binding in context node, without that how I can read data of select option
    in result view?
    Regards,
    Rasmi Ranjan Mishra

    Solve by own.
    If I define the Select options in component controller, then it will be global in nature. so i can get the value of select options
    in another view also.
    Regards,
    Rasmi Ranjan Mishra

  • How to build my own SELECT-OPTIONS?

    Hi experts,
    I hv 4 values like for a field, (say VBAK-BNAME),
    NAME_A
    NAME_D
    NAME_M
    NAME_Z
    My selection- screen is like,
    SELECT-OPTIONS: MANAGER FOR VBAK-BNAME.
    So,
    1) How to build the SELECT-OPTIONS table in my ABAP code?
    I mean, if the user enters the NAME_A TO NAME_Z in select-options, the system shuld take in-between NAMEs also!
    (Actually, I thiught that, the SAP will take care of building the select-options table based on Alphabetical Order, but, When I observed in debug mode, its not like that!)
    2) And Where I hv to write the code for building select-options? I mean, Is it DATA DECLARATION part, AT SELECTION SCREEN or AT SELECTION SCREEN OUTPUT or START OF SELECTION?
    thanq.
    Message was edited by:
            Sridhar
    Message was edited by:
            Sridhar

    Hi,
    Pls. suggest me other than RANGES?
    Well, if you don't want to use RANGE then you can do it at SELECT statement.
    SELECT BNAME
    INTO TABLE ITAB
    FROM VBAK
    WHERE BNAME IN ( NAME_A, NAME_D, NAME_M, NAME_Z )
    OR
    SELECT BNAME
    INTO TABLE ITAB
    FROM VBAK
    WHERE BNAME BETWEEN 'NAME_A' AND 'NAME_Z'.
    2) under which event i hv to write it?
    If you are using in SELECT statement, then you use at START-OF-SELECTION.
    If you are buiding RANGE, then you can use at any events such as INITIALIZATION, AT SELECTION-SCREEN OUTPUT, START-OF-SELECTION, etc.
    Regards,
    Ferry Lianto

  • ECC6.0 t-code COOIS - how to get the "Profile" select-option list

    Hi  PP Gurus
    We are implementing ECC6.0
    We upgraded one of the systems from 4.7 to ECC6.0 (and also kept data: documents, users profiles, variants,u2026etc).
    My question is regarding standard transaction COOIS.
    I do comparison in current 4.7 and ECC6.0 systems (I have SAP_ALL and SAP_NEW in both systems).
    The thing is that in our ECC6.0 system the transaction COOIS doesnu2019t display Profile on select-options screen.
    There are only the following items (select-option screen of COOIS in ECC6.0):
    -LIST
    -LAYOUT
    -Prod.orders checkbox
    -Planned orders checkbox
    u2026And u2018Selectionu2019 tab with other fields
    In the current Enterprise 4.7 system the transaction COOIS displays the following select-option screen:
    -LIST
    -PROFILE
    -LAYOUT
    -Prod.orders checkbox
    -Planned orders checkbox
    u2026And u2018Selectionu2019 tab with other fields
    Questions:
    1.     Is that possible to maintain / see and select a PROFILE in COOIS of ECC6 (or due to new functionality it no more available on that screen ?) How to do that?
    2.     Looking at layouts (I ran COOIS in two systems and compared the results) I canu2019s see in ECC6.0 some icons like u2018Refreshu2019, u2018Order logu2019, u2018Display order componentsu2019, u2018Long textu2019 , u2026.) But all of them are in 4.7 layout. How to get them in ECC6.0 ?
    What I have already explored:
    u2022     ECC6.0 has a new config. t-code COISN (4.7 has only COIS) . I created my new overall profile there, set my own layout, but running COOIS still canu2019t see/use the PROFILE;
    u2022     I have compared the standard structure PPIO_ENTRY_SC1100 in 4.7 and ECC6.0 and found the new component COIS_LISTTYP in ECC6.0. In this situation I ran a new t-code u201CDefine New List Typesu201D (it doesnu2019t exist in 4.7) and created my new entry, but still canu2019t see PROFILE on select-option screen of COOIS in ECC6.0;
    u2022     I also tried situation when both config. transaction COIS (in 4.7 and ECC6.0) had the SAME overall profiles u2013 still canu2019t see PROFILE on select-option screen of COOIS in ECC6.0;
    u2022     I found a new icon u201CNavigation profileu201D in result layout of COOIS ECC6.0 Is that right place where I can maintain the icons I need (see my second question) ?
    THANK YOU.

    Hi,
    The reports are modified if am right as of ECC 5.0. Refer to note - 747469 which gives a list of all reports modified.
    If am right by profile you mean navigation profile, this is now in the display screen. The content remains, only thing is the layout is modified & more structured. So i would suggest you to have a look around in COOIS report & you will find the info.
    The navigation profile is adjacent to the icon called Environment (its a drop down list).
    Revert if you face any issues.
    Regards,
    Vivek

  • How to develop ALV and select-option element in BSP? Help!

    Hi Experts,
    I have a requirement where I have a selection screen with 3 select-option elements and a search button. On clicking the search button an ALV table report has to be shown.
    The ALV table is used for new row/rows entry, delete row/rows and update row/rows data. This is something like table control in normal ABAP.
    Additionaly, I want the download to Excel, sorting, filtering, column swapping options in ALV.
    How can I achieve this in BSP?
    Is there any existing SElect-option and ALV component in BSP?
    Any code sample will be really helpfull.
    How much development time will it take?
    Please help!
    Thanks
    Gopal

    I think you will find that most of what you are looking for does NOT exist out of the box for BSP.  There is no delivered selection-option or value help.  I ended up creating my own over the years (You can find some versions online here in SDN in my weblogs - however a complete implementation of select-options was only delivered along with the Advanced BSP Programming book). 
    There is no ALV either.  However with the htmlb:tableView, you can acomplish quite a bit.  You may have to learn about table view iterators to get it all done.  Downloading to Excel also isn't delivered.  I developed a reusable BSP Extension element for this as well (can be found on SDN in my weblogs or with the Advanced BSP Programming book).
    If you plan to recreate all these elements by yourself, your project will take some time.  It took a while to build so many complex UI elements. 
    What release are you running on?  In Netweaver04S you have Web Dynpro ABAP.  WDA has delivered components for value help, select-options, and ALV.

  • How to attach FCODE to select option in Module Pool

    Hi all,
          I have created Select option in Module pool by attaching a Subscreen. Now when user enters any value into the select option I need to fetch values from the database in to the table control based on the value entered in select option.
    Is it possible and how?
    Thanks.

    <b>Hi
    If u have one select options in module pool programming,Then there is no need for FCODE
    bcoz FCODE is needed for push button,check box..like etc.
    But select option is a input field.
    So u can trace the input as u have done in report
    Like
    select * from dtab1 into corresponding fields of table itab where field1 in <b>selectoption.</b>
    Or if u want that program to be executed after giving input in select option then user will press F8
    So Use FCODE 'F8'.
    Regs
    Manas Ranjan Panda
    Message was edited by:
            MANAS PANDA</b>
    Message was edited by:
            MANAS PANDA

Maybe you are looking for

  • Printing to Canon LBP5000 on express?

    I have acquired a Canon Lasershot LBP5000 colour laser printer. I have connected it via usb to express. My macBook can see it (in print preferences) but when I print NOTHING HAPPENS. CAPT drivers installed successfully on Mac... Any ideas anybody?

  • Hello, I can see the Icon of my external hard on the mac os x 10.6.8 but I can not open it or view any file in the external hard

    hello, I can see the Icon of my external hard on the mac os x 10.6.8 but I can not open it or view any file in the external hard your prompt reply will be appreciated thanks

  • File Name and Path Length Limitations

    Hi guys, We are migrating our Novell NSS Linus File server to Window File server 2008 R2, we do have many directories and files, so of the file names length quite long, is there any tools can be used to identify these files? thx

  • XML Component URL

    Hello, I currently have 3.0.9.8 portal with 9iAS on Sun Solaris 2.8. I'm trying to create an XML Component. It works with static XML created in the XML code window and our customized XSL, however I'm trying to get dynamic XML from the data server by

  • Patch # 6673231

    Patch # 6673231 was on Oracle B2B home page someime ago and we applied that patch in all our non production environments. Now I see only the patch # 6488268 shows up on Oracle B2B home page which is the previous patch. Is the patch # 6673231 withdraw