Selected value in dropdown list box

hi forums,
  how to capture the selected value in drop down list box and how it will link with the table.
layout:
    <htmlb:dropdownListBox  id = "d1%>"
                            nameOfKeyColumn = "vbeln"
                          nameOfValueColumn = "vbeln"
                         table       = "<%=it_sales%>" />
in dropdown list box,how do i capture the selected values.
OnInitialization:
Select vbeln from vbak
  into corresponding fields of table it_sales.
regards,
ravi.

hi Ravikiran,
   In button even,we r mension the event_type = 'click'.
but in dropdownListBox what is the event_type.
i tryed like this.
DATA : EVENT TYPE REF TO CL_HTMLB_EVENT.
***this is for button************
*event = CL_HTMLB_MANAGER=>get_event( RUNTIME->SERVER->REQUEST ).
*IF event->NAME = 'button' AND event->event_TYPE = 'click'.
DATA : button_event TYPE REF TO CL_HTMLB_EVENT_BUTTON.
button_event ?= event.
*ENDIF.
*********this is for dropdownListBox**********
  event = CL_HTMLB_MANAGER=>get_event( runtime->server->request ).
  IF event->name = 'dropdownListBox' AND event-         >event_type = 'selection'.
       DATA :  dd_listbox_event TYPE REF TO CL_HTMLB_EVENT_SELECTION.
       dd_listbox_event ?= event.
CASE EVENT->ID.
when 'id1'.
CALL METHOD REQUEST->GET_FORM_FIELD
      EXPORTING
        NAME  = 'id1'
      RECEIVING
        VALUE = SEL.
WHEN 'myButton'.
   CALL METHOD REQUEST->GET_FORM_FIELD
     EXPORTING
       NAME  = 'id1'
     RECEIVING
       VALUE = SEL.
ENDCASE.
endif.
with regards,
ravi.

Similar Messages

  • Select value from dropdown list

    hi All,
    we have a bsp application MVC based, we have a dropdown list,  what we require is when user selects an entry from drop down list and presses a button, we want to select that value from drop down list and then pass it to the method that will be called when button is pressed event..
    I want to know two things
    1. How do i get the selected value from dropdown ?
    2. hw can i retain it to send it to method call in handle_event bit
    thank you all

    Hi,
    If your application is stateless you have to capture the selected value in do_handle_data and assign it to the controller class attribute and later use this value in do_handle_event directly.
    If your application is stateful, on your dropdownlist htmlb tag click F1 you can read the documentation which also shows how to capture the value of dropdownlist in do_handle_event. In the same documentation you can even find few samples provided and check those samples in your system.
    Hope this helps.
    Regards,
    Abhinav

  • Is it possible to enter our own value in dropdown list box in Module Pool. How?

    Dear Experts,
    Being new to ABAP, I am trying my hands on Dropdownlist box on Module Pool.
    I want to pull data from Ztable(Custom Table) into Dropdown list box on Screen in Module pool and be able to edit it, delete it and enter new data through it, thus thereby able to manage the Ztable. Is it possible in dropdown.
    Looking forward for experts advice.
    Regards
    Deepika

    Dear Kannan,
    Thanks. But why sud I write an event in Table maintenance generator. My code is in Module Pool and it has no connection with Table Msintenance.
    The I/O field Drop down list box is on the Screen in my Module Pool. I am able to pull data in it from Ztable but now I want to edit this pulled data and also want to enter new data in this dropdown list box.
    Regards
    Deepika

  • How to populate table of values based on selected value of dropdown list

    Hi
    I have an urgent requirement.
    Whenever I select a value in Dropdownlist, Based on the selected value I need to display serveral values in tabular form.
    I have created a dynamic LOV and created the actionListener
    I have created a table by dragging the ViewObject and i have set the partialTrigger attribute value to the LOV Id.
    Now My doubt is What should I return in the actionListener method
    Thanks

    Hi,
    So get the value what i tried is ,bind the list item of the select one choice ,
    and then i used the method something like this
    UISelectItems see=getSelectItems1();
    System.out.println("Selected Value"+ see.getValue());
    but it returns me something like this
    Selected Value[javax.faces.model.SelectItem@b20090, javax.faces.model.SelectItem@431753]
    Don't know what are those ,hoe can i get the display value.Please help.
    Thanks

  • Filtering values in a dropdown list box

    Hello Team
    In the BSP application CRM_IC, we want a drop down list box to be filled based on the entry selected from another dropdown list box. We have all the entries for the second drop down box in ABAP internal table .However, we do not want a server round trip to happend in doing so. Thus we have used the attribute 'Onclientselect' and we are trying to call a java script function call on this event to filter this ABAP internal table . In this function, we would like to fill the contents of the second dropdown list box after reading the contents of the first dropdown list box. Please advice us as to how this can be achieved. Basically, we observed that ABAP server side script is not executed in the java function.
    Thanks
    Rony

    Rony,
    I have used the following technique to synchronize the
    contents of two drop down list boxes.
    <b>Scenario:</b>
    The selection in listbox ddlbxSystemEquipNum, which I
    will call "A", determines the contents of listbox
    ddlbxModuleEquipNum, which I will call "B".
    I use a JavaScript array to shadow the ABAP internal
    table containing the possible values for listbox B.
    When the page is initially displayed, listbox B is
    populated from the ABAP internal table.
    When a new selection is made in listbox A, I use the
    onClientSelect event to call a JavaScript function,
    updateModuleList(), to update the contents of listbox B
    from the JavaScript shadow array based on the selected
    value in listbox A.
    <b>Code Excerpts:</b>
    <u>Declare the JavaScript shadow array and listbox B update function</u>
    <script language="javascript" type="text/javascript">
        var moduleArray = new Array();
        function updateModuleList() {
            var selSystem = frmNrg1100.ddlbxSystemEquipNum;
            var selModule = frmNrg1100.ddlbxModuleEquipNum;
            // Get selected system equipment number
            var selected_system =
                    selSystem.options[selSystem.selectedIndex].value;
            // Clear module select options
            selModule.options.length = 0;
            // Add module select options for the selected system
            var j = 0;
            for (var k = 0; k < moduleArray.length; k++) {
                if ( (selected_system == moduleArray[k].system) ||
                                         moduleArray[k].system == "") {
                    selModule.options[j++] = new Option(moduleArray[k].text,
                                   moduleArray[k].value,
                                   moduleArray[k].selected) ;
    </script>
    <u>Specify the onClientSelect event handler on list box A</u>
    <htmlb:dropdownListBox
        id = "ddlbxSystemEquipNum"
        width      = "400"
        onClientSelect = "updateModuleList()"
    <u>ABAP and JavaScript to populate internal table and shadow array of possible values for listbox B</u>
    <%
    loop...
            wa_module_options-system   = wa_customer_tool-equipment_num_t.
            wa_module_options-text     = tool_list_text.
            wa_module_options-value    = wa_customer_tool-equipment_num_m.
            wa_module_options-selected = selected.
            append wa_module_options to module_options.
    %>
    <script language="javascript" type="text/javascript">
        // Add all possible Module select options to a JavaScript array of objects
        moduleArray[moduleArray.length] = {  system:"<%=wa_module_options-system %>",
                                               text:"<%=wa_module_options-text %>",
                                              value:"<%=wa_module_options-value %>",
                                           selected:"<%=wa_module_options-selected %>" } ;
    </script>
    <%
    endloop.
    %>
    Hope this helps.
    Regards,
    Shawn

  • Getting multiple values from a list box

    Hi,
    I am not able to get multiple selected values from a list box using the getParameterValues(). I used the following code..
    String[] names=request.getParameterValues("lname");
    can anyone tell me what the error is or is there any other way i can get multiple selected values from a list box.
    Thanks
    Satish

    Fragment 1
    This is the JSP Code am using for testing
    <%
    String[] name =request.getParameterValues("D1");
    if(name.length==1)
    String value=name[0];
    Instead of name.lenght==1 try with name!=null
    Fragment 2
    out.println(value);
    replace the above fragment with
    %>
       <%-- print result -->
       <%=name[0]%>
    <%
    Fragment 3
    else
    %>
    The list box D1 is a multiple select list box.
    If it still doesn't work, check that the checkboxes have the same name as well as different values
    <input type="checkbox" name="D1" value="1">
    <input type="checkbox" name="D1" value="2">I hope this helps :-)
    Good luck
    touco
    ps: i want duke

  • How to read the selected value of a dropdown list box

    Hello,
    I have 2 custom fields which are of type dropdown list on Accounts(CRMM_ACCOUNT) PCUI application details tab.I need to read the selected value of first dropdown list item,based on that second dropdown list will be populated.
    I know where to populate the dropdown list box,it is in FILL_DROPDOWN_LISTBOX.
    I dont know how to trap the selection made on dropdown list.
    PLease guide me on how to trap the dropdown list field selection value.
    Thanks in advance.
    Thirumala.

    Hello,
    Check what is done in standard for the fielf REGION which is inked to the country.
    Otherwise, you can do the following :
    - in field group customizing, for field 1, flag the 'send request' flag. So, when you change the value in this field via the dropdown, the MAC methods are immediately called.
    - Put the new value in a global variable (GV).
    - in the fill_dropdown_listbox method, get the value from this GV and based on it, filter the values for the dropdown of field 2.
    Hope this will help you,
    Regards,
    Frederic

  • How to attach value range table to dropdown list box

    Hi there,
    could u please explain me how to attach a value range table to dropdown list box (i.e I/O box with dropdown attribute as list with key).
    if possible please explain me with a sample code.
    Thanks in advance.
    -Tulasi.

    hi ...if the associated domain of the field that u are using as i.o field has value range the same will come as drop down list...u u select the list box option and click from dictionary check box on the attributes...
    To check if the domain has it or not...go to the domain..click on value range..u can see thr,...if values are not thr u can giv the same...
    Or if u are not refering to dictionary type then use fm VRM_SET_VALUes
    reward if the abv is helpful..

  • After selecting the value from the list box, want to disable checkbox

    hi guru,
    After selecting the value from the list box, want to disable checkbox and custom control textbox(container) in module pool.
    so please help me on this.
    thanx,
    man

    in PBO,
    loop at screen.
      if screen-name = your textbox's name.
        screen-input = 0.
        modify screen.
      endif.
    endloop.

  • LiveCycle 8.1 on Vista: dropdown list box doesn't show all values

    On Vista Business O/S, in LiveCycle 8.1, I am using a dropdown list for 254 items, not dynamically loaded (all values are declared in the definition of the object). When the form runs, the dropdown list appears. I can scroll through the list. However, the scroll stops short, never showing the last few items on the list.<br /><br />   Is there some limit I have exceeded or is there some know bug I have encountered or is there some other action I need to take so I can choose any item from the dropdown list?<br /><br />   Dropdown list box is defined as user-entered - optional, default <none>.<br />254 text items, longest item is 19 characters, average item is 10 characters long. <br /><br />   Thanks in advance for any help, hints, or tips you provide.<br /><br />Dr. Dave Dyer

    Dear Friends....
    it seems to be a bug of the SQL Server Data Tools, (SQL Server 2012 SP2)... I did the deploy of my Dashboard, (and details Reports), to my Test Reporting Services Server.. and everything works as expected....
    Cheers, Luis

  • ADF  Get selected values from Dynamic Lists

    Hi,
    I have a created a dropdown list box where the list gets value through a managed bean. On commit I want the selected value to be saved into the CardiacV1EchoSched column of the Entity object (database). The source looks like this.
    <af:selectOneChoice value="#{bindings.CardiacV1EchoSched.inputValue}"
    label="#{bindings.CardiacV1EchoSched.label}"
    valuePassThru="true">
    <f:selectItems value="#{TTrack.carScheList}"/>
    </af:selectOneChoice>
    The problem is that getCardiacV1EchoSched() in the entity object class is null. The selected value does not get passed into #{bindings.CardiacV1EchoSched.inputValue} at all. If I bind the value to a variable in managed bean I get the selected value.
    Thanks in advance,

    Hi,
    not sure which business service you use to update the database, but if you use ADF Business Components then you need to call the commit operation
    Frank

  • Dropdown list boxes

    Hi friends,
    Could u please tell me how to create a module pool program to charge the content of a a field of database table in a Dropdown list boxes . Please provide me step by step Process or link of file.
    thinks .

    Hi Karim,
    see the below programs to fill the field with a valid listbox value, for example, in this program, I am building the listbox in the program and just assign P_FIELD a valid value from internal table'ivrm_values' . Create screen 100 and create a field call P_FIELD, make sure to select "ListBox" from the DropDown Field.
    report  zpavan_0001.
    type-pools: vrm.
    data: p_field(20) type c.
    data: ivrm_values type vrm_values.
    data: xvrm_values like line of ivrm_values.
    data: name type vrm_id.
    start-of-selection.
    Set default value, before calling the screen
      p_field = 'DEF'.
      call screen 100.
    *&      Module  STATUS_0100  OUTPUT
          text
    module status_0100 output.
    SET PF-STATUS 'xxxxxxxx'.
    SET TITLEBAR 'xxx'.
    name = 'P_FIELD'.
      xvrm_values-key = 'ABC'.
      xvrm_values-text = 'ABC'.
      append xvrm_values to ivrm_values.
      xvrm_values-key = 'DEF'.
      xvrm_values-text = 'DEF'.
      append xvrm_values to ivrm_values.
      xvrm_values-key = 'GHI'.
      xvrm_values-text = 'GHI'.
      append xvrm_values to ivrm_values.
      call function 'VRM_SET_VALUES'
           exporting
                id     = name
                values = ivrm_values.
    endmodule.                 " STATUS_0100  OUTPUT
    *&      Module  USER_COMMAND_0100  INPUT
          text
    module user_command_0100 input.
    endmodule.                 " USER_COMMAND_0100  INPUT
    Thanks and Regards,
    Pavankumar

  • How do I populate form fields depending on the value of a list box?

    Hi,
    Can anybody help me out here?
    I'm creating a form where I'm needing to populate a number of fields (first name & last name) based on the value of a list box (values are 1,2,3,4,5,6) ie: if 3 is selected 3 sets of the first name and last name fields populate on the page for the user to fill out.
    At this stage it is just a prototype site and there is no database running behind it.
    Thanks
    Hayden

    This can only be solved if you have javascript coding skills.  Without knowing more about what you want to do and why, I can only show you a skeleton of how your code should look, but consider this form select field -
    <select onchange="populateForm()">
    When a value is selected from that list, the "onchange" event will fire, and will call the javascript function called populateForm().  You need to define a function by that name somewhere on the page -
    <script type="text/javascript">
    //<![CDATA[
    function populateForm(value) {
         if value >0 { document.getElementById("fieldID").style.display='block' }
         if value >1 { .... }
         etc.
    //]]>
    </script>
    The page itself would need to have ALL the fields already in the form, but with those that are to be revealed set to a style of display:none.
    Obviously, this is a skinny skeleton.  Each test in the function would reveal a new field on the page by changing its display style from "none" (which is how they should be set in the code) to "block".  You would need a separate function for each type of field that might need to be chosen.
    If this is well over your head, then I'm afraid you will be out of luck for this particular approach....

  • 2 cascading multiple dropdown list boxes that fill a form field in Infopath

    I have a request to do this:
    first field is a cascading list box is type of work (can select more than 1 type of work)( separate list)
    then based on the choices above the
    second cascading list box has the various people's names from the first list box (can select more than 1 person)(separate List )
    then I need to from the second list box have a form field hold the various email addresses of all the people selected in the second list box.
     how would I do a multiple tier cascade in Infopath form?

    those are good examples, but here is the thing the first two dropdowns can be more than 1 selection, could be 50 items selected.
    and selection 2 dropdown doesnt lookup into  selection 1. but they do have a related column.
    company name..... ( just  saying).

  • How to get the selected values from multiselected list

    Hi,
    I have a multiselect list displaying all the years from 2003 to 2008 (used dynamic LOV). The user can choose one or more years as per his needs, and then when user clicks on the link the selected values of the list are to be captured and a pop up page of a Discoveror report needs to be opened where these years get passed as a parameter. I tried several methods to capture the value, but either one or all are getting passed but not exactly what the user has chosen.
    This is how it looks:
    P2_FISCAL_YEAR is a multiselect list containing values from 2003,2004... 2008
    If user chooses 2004 and 2007
    then I want the url to capture these values and pass as parameters for my discoveror reports. as '&qp_fiscal_year=2004,2007'
    Any help is appreciated!
    Thanks in advance,
    Sapna.

    Hi,
    I have a multiselect list displaying all the years from 2003 to 2008 (used dynamic LOV). The user can choose one or more years as per his needs, and then when user clicks on the link the selected values of the list are to be captured and a pop up page of a Discoveror report needs to be opened where these years get passed as a parameter. I tried several methods to capture the value, but either one or all are getting passed but not exactly what the user has chosen.
    This is how it looks:
    P2_FISCAL_YEAR is a multiselect list containing values from 2003,2004... 2008
    If user chooses 2004 and 2007
    then I want the url to capture these values and pass as parameters for my discoveror reports. as '&qp_fiscal_year=2004,2007'
    Any help is appreciated!
    Thanks in advance,
    Sapna.

Maybe you are looking for

  • How do I get my apps back after sync to MBP, Upgrade to iOS5?

    After Sync'ing my iPhone 4 to MBP, I upgraded to iOS5 on the iPhone and Lion on the MBP.  Now, my icons for iPhone apps are on the MBP.  I don't see how to get them back to the iPhone.  The former "Apply" button has disappeared.  What is the new proc

  • Is there any way to convert to XML object to file

    hi is there any method or class which convert the DOM object to file ... bye with regards elan

  • Opening MPEG 4s in FCP

    I want to bring a movie I downloaded from the iTunes store in FCP. I opened it in Quicktime, but it won't let me export it into a different file type, and FCP won't let me import the file. Is there any way to somehow get it into FCP?

  • Shipping point determination - ME2O

    I'm using ME2O for creating a delivery. I select a line and i press the Create delivery button. A popup appears but the filed Shipping point is empty. What configuration should i make to have a value in that field? The shipp. points are assigned to t

  • Catalog and Non catalog?

    Hi, what is the difference between catalog and non catalog ? Thanks,