Select option in Dialog program screen

Hi friends,
do we have any way to get a select option displayed in dialog programming ?
or
create a screen field with the properties of a select option in dialog screen ?
or
any standard function module to support this scenario ?
Thanks and Regards
Sakthi.

Hi,
i don't know you checked it or not, but i am able to do it, i send the screen shot also to you check it..
it is possible,with some coding also  check it once...
REPORT  ZTEST_SCREEN                            .
DATA : BEGIN OF IT_DYNPFIELDS OCCURS 3.
        INCLUDE STRUCTURE DYNPREAD.
DATA : END OF IT_DYNPFIELDS.
DATA: TEST(10) TYPE C.
RANGES:  R_UNAME FOR SY-UNAME.
DATA:     V_USERNAME LIKE  SY-UNAME.
DATA : V_PROG LIKE D020S-PROG VALUE 'ZTEST_SCREEN',
       V_DNUM LIKE D020S-DNUM VALUE '0100'.
CALL SCREEN 100.
*&      Module  STATUS_0100  OUTPUT
*       text
MODULE STATUS_0100 OUTPUT.
  SET PF-STATUS 'TEST'.
*  SET TITLEBAR 'xxx'.
ENDMODULE.                 " STATUS_0100  OUTPUT
*&      Module  USER_COMMAND_0100  INPUT
*       text
MODULE USER_COMMAND_0100 INPUT.
  CASE SY-UCOMM.
    WHEN 'BACK'.
      LEAVE TO SCREEN 0.
  ENDCASE.
ENDMODULE.                 " USER_COMMAND_0100  INPUT
*&      Module  GET_CURSOR_USERNAME  INPUT
*       text
MODULE GET_CURSOR_USERNAME INPUT.
  REFRESH IT_DYNPFIELDS.
  CLEAR   IT_DYNPFIELDS.
  MOVE 'V_USERNAME' TO IT_DYNPFIELDS-FIELDNAME.
  APPEND IT_DYNPFIELDS.
  CLEAR   IT_DYNPFIELDS.
  CALL FUNCTION 'DYNP_VALUES_READ'
    EXPORTING
      DYNAME               = V_PROG
      DYNUMB               = V_DNUM
      TRANSLATE_TO_UPPER   = 'X'
    TABLES
      DYNPFIELDS           = IT_DYNPFIELDS
    EXCEPTIONS
      INVALID_ABAPWORKAREA = 1
      INVALID_DYNPROFIELD  = 2
      INVALID_DYNPRONAME   = 3
      INVALID_DYNPRONUMMER = 4
      INVALID_REQUEST      = 5
      NO_FIELDDESCRIPTION  = 6
      INVALID_PARAMETER    = 7
      UNDEFIND_ERROR       = 8
      DOUBLE_CONVERSION    = 9
      STEPL_NOT_FOUND      = 10
      OTHERS               = 11.
  IF SY-SUBRC = 0.
    READ TABLE IT_DYNPFIELDS WITH KEY FIELDNAME = 'V_USERNAME'.
    IF SY-SUBRC = 0.
      V_USERNAME = IT_DYNPFIELDS-FIELDVALUE.
    ENDIF.
  ENDIF.
  PERFORM GET_MULTIPLE.
ENDMODULE.                 " GET_CURSOR_USERNAME  INPUT
*&      Form  GET_MULTIPLE
*       text
*  -->  p1        text
*  <--  p2        text
FORM GET_MULTIPLE .
* Dynamically holding Field name
  FIELD-SYMBOLS: <FST> TYPE STANDARD TABLE.
  IF  R_UNAME[] IS INITIAL.
    IF NOT V_USERNAME IS INITIAL.
      R_UNAME-SIGN = 'I'.
      R_UNAME-OPTION = 'EQ'.
      R_UNAME-LOW = V_USERNAME.
      APPEND R_UNAME.
      CLEAR  R_UNAME.
    ENDIF.
  ENDIF.
  ASSIGN R_UNAME[] TO <FST>.
  CALL FUNCTION 'COMPLEX_SELECTIONS_DIALOG'
    EXPORTING
      TITLE             = 'Select Multiple Value'(059)
      TEXT              = 'Finish Group'(058)
      SIGNED            = 'X'
      LOWER_CASE        = ' '
      NO_INTERVAL_CHECK = 'X'
      JUST_DISPLAY      = ' '
      JUST_INCL         = 'X'
    TABLES
      RANGE             = <FST>
    EXCEPTIONS
      NO_RANGE_TAB      = 1
      CANCELLED         = 2
      INTERNAL_ERROR    = 3
      OTHERS            = 4.
  IF SY-SUBRC = 0.
    READ TABLE R_UNAME INDEX 1.
    IF SY-SUBRC = 0.
      V_USERNAME = R_UNAME-LOW.
    ENDIF.
  ENDIF.
ENDFORM.                    " GET_MULTIPLE
Flow loogic....
PROCESS BEFORE OUTPUT.
MODULE STATUS_0100.
PROCESS AFTER INPUT.
MODULE USER_COMMAND_0100.
PROCESS ON VALUE-REQUEST.
*- To capture the cursor and for f4
  FIELD V_USERNAME      MODULE GET_CURSOR_USERNAME.
in screen i have one field v_username
for that field do this
<b>double click on field which you want to make it as select option, it will display the attributes screen, in that click on program attributes button , now go to poss. entries in the dropdown choose 1 show at selection.</b>
Regards
vijay

Similar Messages

  • Select-Option in Dialog programming

    Hi Experts,
      Can we use select-options in Dialog programming?
    If yes, Please help me, how to do that?
    <REMOVED BY MODERATOR>
    Edited by: Alvaro Tejada Galindo on Jun 12, 2008 12:27 PM

    Hi Asrar,
    Definitely you can use select-options in dialog programming.
    You can do this using Subscreen.
    define this scubscreen in top include.
    selection-screen : begin of screen 100 as subscreen.
    select-option : kunnr for kna1-kunnr.
    selection-screen : end of screen 100.
    in screen 200 where this selection screen appears, create a subscreen area 'SSA'.
    Process on output. "200 screen.
    call subscreen SSA including sy-repid '100'.
    other modules
    Process on input.    "200 screen.
    call subscreen SSA.
    other modules
    now you can access kunnr like other screen 200 objects.
    <REMOVED BY MODERATOR>
    Regards
    Megha
    Edited by: Alvaro Tejada Galindo on Jun 12, 2008 12:27 PM

  • Select-options in Dialog Programming

    Hi,
    I am designing a custom dialog programming screen.
    I want to create a filed on thescreen which can allow the range of values to be entered like select-options in a report.
    How do I create a field which can accept range of values in dialog programming?
    Thanks,
    Ashok.

    Hi,
    In your selection screen program, Use Export  command
      Export r_Purchase_Order To Memory Id 'PO'.
                 Export r_Po_Item        To Memory Id 'POITEM'.
                 Export r_Plant          To Memory Id 'PLANT'.
                 Export r_Vendor         To Memory Id 'VENDOR'.
                 Export r_Material       To Memory Id 'MATNR'.
                 Export r_Batch          To Memory Id 'BATCH'.
                 Export r_Arrival_Date   To Memory Id 'ADATE'.
                 Export r_Arrival_Time   To Memory Id 'ATIME'.
                 Export r_Delivery_No    To Memory Id 'DEL'.
                 Export r_Reference_No   To Memory Id 'REF'.
                 Export r_User           To Memory Id 'USER'.
                 Export t_Display_Data   To Memory Id 'DISPDAT'.
    In your Module pool program, Use Import Command
        When c_Ok_0100_Execute.
                   IMPORT r_Purchase_Order From Memory Id 'PO'.
                   IMPORT r_Po_Item        From Memory Id 'POITEM'.
                   Import r_Plant          From Memory Id 'PLANT'.
                   Import r_Vendor         From Memory Id 'VENDOR'.
                   Import r_Material       From Memory Id 'MATNR'.
                   Import r_Batch          From Memory Id 'BATCH'.
                   Import r_Arrival_Date   From Memory Id 'ADATE'.
                   Import r_Arrival_Time   From Memory Id 'ATIME'.
                   Import r_Delivery_No    From Memory Id 'DEL'.
                   Import r_Reference_No   From Memory Id 'REF'.
                   Import r_User           From Memory Id 'USER'.
                   Import t_Display_Data   From Memory Id 'DISPDAT'.
    Thanks

  • Select-Options in dialog program

    Hi there,
    I'm using a selection-screen in a dialog program, I declared it in the TOP.
    Selection-screens
    SELECTION-SCREEN BEGIN OF SCREEN 101 AS SUBSCREEN.
    parameters: p_lifnr type lfa1-lifnr  obligatory ,
                p_werks type t001w-werks obligatory .
    SELECT-OPTIONS:
      s_licha FOR zbrtconsig-licha.
    SELECTION-SCREEN END OF SCREEN 101.
    I have to use the event at selection-screen on value-request for s_licha-low, and I need the values from the fields p_lifnr and p_werks. the problem is:
    If I only fill the fields p_lifnr, p_werks and click on F4 for s_licha, the values of p_lifnr and p_werks are not updated, they are empty. Only wether I do an Enter this fields is updated.
    Thanks,
    Alexandre Nogueira

    Hi,
    i am not clear about your problem, please expalin it clearly.
    use FM : DYNP_VALUES_UPDATE to update screen fields.
    use FM : DYNP_VALUES_READ to read screen fields.
    use SET /GET Parameter id's to set parameters
    this FM will update the screen fields before to PBO event.
    check this link for sample code :
    Re: Issue Related to Module pool
    Regards
    Appana

  • Slect-options in Dialog program

    Hi,
    How to bring Select-options parameter in dialog program ? i.e
    I want to give a parameter like select-options in dialog program .
    Thanks in Advance.
    Regards
    Ranjith

    Hi
    Treat Dialog pgm also as report---
    u can declare as below in TOP include
    SELECTION-SCREEN BEGIN OF SCREEN 030 AS WINDOW TITLE text-t08.
    SELECTION-SCREEN SKIP.
    SELECTION-SCREEN BEGIN OF BLOCK s1
                              WITH FRAME TITLE text-t08.
    PARAMETERS:
    ra_own          RADIOBUTTON GROUP rad3,
    ra_all          RADIOBUTTON GROUP rad3.
    SELECTION-SCREEN END OF BLOCK s1.
    SELECTION-SCREEN END   OF SCREEN 030.

  • Select option in user defined screen

    Hi friends,
    In my program i m in need of using select-options ( input in terms of range ) . i saw some thread . in that they have mentioned FM : COMPLEX_SELECTIONS_DIALOG and some have given call subscreen ***.
    but i don't know how to use it. i have never used subscreen in my program..
    so u please tell me how to get it.
    Thanks and regards,
    kani,.

    Refer:
    [http://www.saptechies.com/select-option-in-a-dynpro/]
    [Complex_Selections_dialog in Module Pool Programming;
    [How to put "selection options without intervals" on screen painter?;

  • Select option in modular programming...?

    Hi Abapers,
                     I have a problem where in i want to use select options in modullar programming.....
    and one more thing that when ever i  am using an EXECUTE button which has been defined manually by me..
    the report show the output but wen i am coming back to the screen and again i am using EXECUTE  butto
    the value are repeated..
    so can anyone answer to both of my questions pls......

    for answer to ur first Question
    Best option is to go for a report program
    If still you need to go for module pool there is one solution.
    1. Define a subscreen on ur screen.
    2. Define The screen as we do in report program but with addition 'AS SUBSCREEN' .
    3.call the subscreen in ur flow logic of main screen.
    Following code may help.
    define this in ur top include.
    SELECTION-SCREEN BEGIN OF SCREEN 200 AS SUBSCREEN.
    SELECT-OPTIONS:
                    s_vkorg1  FOR zadvhead-vkorg  NO-EXTENSION NO INTERVALS,
    SELECTION-SCREEN END OF SCREEN 200.
    in screen flow logic
    PROCESS BEFORE OUTPUT.
    CALL SUBSCREEN subscr_is1 INCLUDING sy-repid dynnr_is1.
    "dynnr_is1 = 0200 & subscr_is1 = subscreen area name
    PROCESS AFTER INPUT.
    CALL SUBSCREEN subscr_is1.
    for more info
    Re: Module Pool Program
    Edited by: mrugesh phatak on Oct 1, 2008 12:23 PM

  • Getting select options in module pool screen

    hi experts,
    can any one suggest me how to provide select options in module pool screen.
    thank you,
    regards
    vijay

    Hi,
    Take two fields on screen first for low value and other for high value (say vbeln_low and vbeln_high) also design a button next to the high textbox for select-option button used to display popup.
    Using these two input fields append a range (say r_vbeln for vbap-vbeln) for the field to be used (either in query or anywhere).
    ranges : r_vbeln for vbap-vbeln.
      IF NOT vbeln_high IS INITIAL.
        IF NOT vbeln_low LE vbeln_high.
          MESSAGE e899 WITH text-007. "high value is smaller than low value
        ENDIF.
      ENDIF.
      r_vbeln-sign = 'I'.
      r_vbeln-low = vbeln_low.
      IF vbeln_high IS INITIAL.
        r_vbeln-option = 'EQ'. "if user takes only a singlr value
      ELSE.
        r_vbeln-option = 'BT'. "if user takes both low & high value
        r_vbeln-high = vbeln_high.
      ENDIF.
      APPEND r_vbeln. "append range
      CLEAR r_vbeln.
    On the button click call this FM to call a popup for select-options.
    DATA : tab TYPE rstabfield.
    tab-tablename = 'VBAP'.
    tab-fieldname = 'VBELN'.
      CALL FUNCTION 'COMPLEX_SELECTIONS_DIALOG'
       EXPORTING
         title                   = text-002
         text                    = ' '
         signed                  = 'X'
    *         lower_case              = ' '
    *         no_interval_check       = ' '
    *         just_display            = ' '
    *         just_incl               = ' '
    *         excluded_options        =
    *         description             =
    *         help_field              =
    *         search_help             =
         tab_and_field           = tab
        TABLES
          range                   = r_vbeln
       EXCEPTIONS
         no_range_tab            = 1
         cancelled               = 2
         internal_error          = 3
         invalid_fieldname       = 4
         OTHERS                  = 5.
      IF sy-subrc EQ 2.
        MESSAGE s899 WITH text-003. "no value selected
      ELSEIF sy-subrc <> 0 AND sy-subrc <> 2.
        MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      ENDIF.
    This whole code will append your range r_vbeln to be used in program.
    Hope this solves your problem.
    Thanks & Regards,
    Tarun Gambhir

  • How to creat select-option on module pool screen???

    Hi All,
       please tell me how to creat select-option on module pool screen???
    Regards
    Deepak

    Hi Deepak Kumar Sharma,
    There are Two ways to achieve it...
    1) How to create a select-options in a module pool screen.
    Method 1
    a) Create a subscreen area in your screen layout where you want to create the select options.
    b) In the top include of your module pool program declare a selection screen as a subscreen e.g.
    SELECTION-SCREEN BEGIN OF SCREEN 100 AS SUBSCREEN.
    select-options s_matnr for mara-matnr.
    SELECTION-SCREEN END OF SCREEN.
    c) In the PBO and PAI of the main screen where the select options needs to be created do a call subscreen of the above screen (100).
    CALL SUBCREEN sub_area INCLUDING <program> <screen>
    This call subscreen statement is necessary for transport of values between screen and program.
    Note: All validations of the selection screen fields e.g. the s_matnr field created above should be done in selection screen events like AT SELECTION-SCREEN etc and not in PAI. These selection screen validations etc should be done in the top include only.
    Method 2
    a) Create 2 separate fields in your screen layout - one for the low value and one for the high value. Insert an icon beside the high value which will call the multiple selections popup screen on user command. Use function module COMPLEX_SELECTIONS_DIALOG to achieve this.
    struc_tab_and_field-fieldname = con_cust. " 'KUNNR'
    struc_tab_and_field-tablename = con_kna1. " 'KNA1'.
    CALL FUNCTION 'COMPLEX_SELECTIONS_DIALOG'
    EXPORTING
    TITLE = ' '
    text = g_titl1 " 'Customers'
    tab_and_field = struc_tab_and_field
    TABLES
    RANGE = rng_kunnr
    EXCEPTIONS
    NO_RANGE_TAB = 1
    CANCELLED = 2
    INTERNAL_ERROR = 3
    INVALID_FIELDNAME = 4
    OTHERS = 5.
    IF NOT rng_kunnr[] IS INITIAL.
    Read the very first entry of the range table and pass it to
    dynpro screen field
    READ TABLE rng_kunnr INDEX 1.
    IF sy-subrc = 0.
    g_cust = rng_kunnr-low.
    ENDIF.
    You can use the return table rng_kunnr to populate your own internal range table with the values entered by the user. Basically here you are just simulating the work of a select-options parameter by module pool screen elements.
    Also have a look on below threads
    how to make select option in module pool
    select option in module pool program
    Hope it will solve your problem..
    Thanks & Regards
    ilesh 24x7

  • Select Option on Module Pool screen

    How to display select options on Module Pool screen ?

    Via the search functionality, you will find something like :
    SELECTION-SCREEN BEGIN OF SCREEN 101 AS SUBSCREEN.
    SELECT-OPTIONS: S_CARRID FOR SPFLI-CARRID,
                    S_CONNID FOR SPFLI-CONNID.
    SELECTION-SCREEN END OF SCREEN 101.
    and to use a CALL SELECTION-SCREEN xxxx in your module pool.
    regards,
    Hans

  • Calling dialog program screen in custom control and using drag n drop

    Hi Experts,
    SCENARIO:
    I have a custom container control. I want to insert a dialog program screen in custom container control in one half and tree nodes in the other half.
    Now my dialog screen has a table control. I want that the user can drag n drop the nodes in the cells of my table control.
    Please help.

    I don't think drag n drop works in table control. You may need to change table control to ALV grid control.

  • Creating Variant in Dialog Program Screen

    Hi All,
    Can I create Variant in Dialog Program screen.If yes, how can I do this?
    Thanks
    Saurabh

    dfsdf

  • Hiding Select options on a selction screen

    hi,
    How to Hide Select options on a selction screen
    thnks.

    hi,
    eg:-
    select-options: sel_mat for mard-matnr no-display.
    select-options: sel_plnt for mard-werks.
    in this the sel_plnt will appear and sel_mat will not be seen on the selction screen. there are many options avaliable with select-options..
    Like
        [OBLIGATORY / NO-DISPLAY]
        [VISIBLE LENGTH vlen]
        [NO-EXTENSION]
        [NO INTERVALS]
        [MODIF ID modid] ... .
    reward points if useful and mark answered if u got the answer 

  • Select options in dialog screen

    Hi all,
    I have used this logic in my program (ZSDIC001),
    selection-screen begin of screen 1010 as subscreen.
    selection-screen begin of block b1 with frame title text-001.
    parameters: p_rad1 radiobutton group grp1 default 'X',
                p_rad2 radiobutton group grp1,
                p_rad3 radiobutton group grp1.
    select-options: s_matnr for  mara-matnr,
                    s_matkl for  mara-matkl,
                    s_mtart for  mara-mtart.
    selection-screen end of block b1.
    selection-screen end of screen 1010.
    start-of-selection.
      call screen 100.
    *&      Module  STATUS_0100  OUTPUT
    module status_0100 output.
    SET PF-STATUS 'xxxxxxxx'.
    SET TITLEBAR 'xxx'.
    endmodule.
    *&      Module  USER_COMMAND_0100  INPUT
    module user_command_0100 input.
    endmodule.
    create   screen 100 and create a subscreen area called "subscreen_1010"
    Screen Flow Logic follows
    *process before output.
    module status_0100.
    call subscreen subscreen_1010 including sy-repid '1010'.
    *process after input.
    call subscreen subscreen_1010 .
    module user_command_0100.
    But i get this error,
    Error when generating the selection screen "1010" of report "ZSDIC001".
    Can anyone help me out to solve this problem.
    Thanks,
    Rajesh.

    I've copied your code and it generated fine without any error.
    Possibly your subscreen container is to small.
    Regards
    Tobias

  • Select option in Dialog prog

    Hi,
    I'm developing a dialog programming. 1st screen is the selection screen, i need to code the input for Parameter -> Material number , Select-option -> Plant. Problem hits on select option Plant.
    If we code via normal type 1 executable program, i just need code like -> Select-options: S_PLANT for mara-werks. Since right now im in dialog programming then i need to code my own LOW and HIGH value. I have done that. But i need to code in the Multiple selection/Extension button that next to HIGH.
    Do u guys know is there any FM that helping to create Multiple selection/Extension button? Like standard once click on it, it contains single value, ranges, exclude single value, exclude ranges...
    Please comment.

    Hi,
    1. Create the subscreen using the selection screen
    2. Create the subscreen area in the Dialog program
    3. Call this subscreen created  in point 1 in the subscreen area of dialog programing.
    selection-screen : begin of screen 0050 as subscreen.
    select-option : s_pernr for pa0000-pernr.
    selection-screen : end of screen 0050.
    start-of-selection
    call screen 100.
    in PBO
      call subscreen <subscreen area>including sy-repid '0050'.
    in PAI
      call subscreen <subscreen area> .

Maybe you are looking for

  • ICal error message- 403

    iCal on my MacBook Pro keeps popping up with this message no matter what I do 'Access to account "iCloud" is not permitted.  The server responded: "403" to operation CalDAVAccountRefreshQueueableOperation I have tried unchecking iCal on my iCloud and

  • B&W G3 gets Black Rectangle on Boot - Hangs

    My B&W G3 will not boot OS X 10.4 anymore. It worked fine before. Now when it boots I get the Apple logo then I get a solid black rectangle in the middle of the screen and it hanges. I put the 10.4 DVD in the drive and pressed C on boot. It starts to

  • LabVIEW DSC: Migration from 6.1 to 8.6 problems

    Colleagues, I need help from someone who experienced with LabVIEW DSC. I would like to recompile pretty old application written in LabVIEW 6.1/DSC 6.1 to LabVIEW 8.6, and got lot of troubles with this. At the first I have tried to migrate my old scf

  • Control of Siemens Simotion over XML-OPC

    HI, I am trying to control a Siemens Simotion unit over XML-OPC. With a XML-Browers we can access the data inside the Simotion. But it was not possible to open a connection with CVIXMLLoadDocument Does anyone of you have experience with XML programmi

  • Change in Delivery Address in PO

    Hi, My user is asking me to Change the Delivery Address mentioned in the PO. Please let me know from where does the delivery address in PO comes from. If  i need to change this delivery addres, where should i make the changes in Configuration.  Pleas