How to retain selected value in apex_item.select_list?

Hi,
I've a report region query-
select distinct col1, col2,
APEX_ITEM.HIDDEN(2,col3)||
APEX_ITEM.SELECT_LIST(1,'No_Action','Valid;Y,Invalid;N') Action
from <tab1>
When 'Y' (valid) selected from the select list and SUBMIT is clicked - a validation and then page processing pl/sql process will run for the record, branching to the same page.
If validation fails custom error message comes on screen, but value of column "Action" is reset to default 'No_Action'.
Can anyone please tell me how can I show the last selected value in column "Action"?
Please reply asap. Regards.

To be able to show the last selected value you need to make the value persistent, that is update it in some column in the table.
So the next time the report is run (refreshed) it fetches the value from the table/column . Then change your query to something like
select distinct col1, col2,
APEX_ITEM.HIDDEN(2,col3)||
APEX_ITEM.SELECT_LIST(1,NVL(COL_YN,'N'),'Valid;Y,Invalid;N') Action
from <tab1>COL_YN is the column where you stored the last selection. Unless you store it in some table/column you cannot get it back into the report when it is refreshed.
The other way of course is to use APEX_COLLECTIONS , but that might be more complex.
However, you need to think whether you really need the APEX_ITEMs API for this? If you just edit the Report Attributed and Edit the column definitions you might be able to achieve the same thing without having to use APEX_ITEM.
Regards,

Similar Messages

  • How to get selected value from selectOneRadio ???

    Hi...i want to how to get selected value from selectOneRadio and use it in another page and in backing bean.
    Note i have about 10 selectOneRadio group in one page i want to know value of each one of them.
    Plzzzzzzzz i need help

    You have a datatable in which each row is a question, correct?
    Also in each row you have 5 possible answers that are in a radio, correct?
    So,
    You need to put in your datatable model, a question, and a list of answers (5 in yor case) and the selected one.
    So you will have a get to the question, an SelectItem[] list to populate the radios and another get/set to the selected question.
    ex:
    <h:selectOneRadio value="#{notas.selectedString}" id="rb">
    <f:selectItem itemValue="#{notas.valuesList}"/>
    </h:selectOneRadio>
    Search the web for examples like yours.

  • How to get selected value from OADefaultListBean.

    Hi All,
    How to get selected value from OADefaultListBean ?
    Thanks,

    Hi,
    To identify the user's selection(s) when the page is submitted, you would add the following logic to your processFormRequest() method:
    OADefaultListBean list =
    (OADefaultListBean)webBean.findChildRecursive("positionsList");
    String name = list.getName();
    String[] selectedValues = pageContext.getParameterValues(name);
    To retrieve all the values in the list box, call list.getOptionsData().
    --Prasanna                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • How to get selected values from selectManyCheckbox ?

    Hi,
    I am a SOA developer and using 'Auto generated adf form' of Human Task. I did some customization in the form. I need to show one dynamic list (contains multiple string values) on a form, from which user will select desired values. For this I have used <af:selectManyCheckbox> adf component.
    It has generated code as follows...
    <af:selectManyCheckbox value="#{bindings.Response.inputValue}"
                                             label="#{bindings.Response.label}"
                                             id="smc1">
                        <f:selectItems value="#{bindings.Response.items}" id="si9"/>
    </af:selectManyCheckbox>
    I am able to show list on a form and can select multiple values also.
    Now, I want the multiple selected values back in my BPEL process. I need only those values which are selected by user.
    Currently I am getting complete list as it is back in BPEL process.
    Please help me out..!
    Thanks..
    Suraj

    Unwinding ADF: How to retrieve Selected Items from selectManyCheckbox using ValueChnageListener

  • How to get selected values from Select Many Choice List

    Hello All -
    I am using Select Many Choice List and wish to get the selected values in the bean. I have created method binding for valueChangeListener for the choice list, but not sure how to get the selected values.
    I am facing problem in getting values from valueChangeEvent.getNewValue(). For Select One Choice List this returns int, but some list type object for Select Many Choice List.
    When I try to print the value it comes something like:
    ArrayList newVal = new ArrayList(Arrays.asList(valueChangeEvent.getNewValue()));
    System.out.println(newVal);
    [Ljava.lang.Integer;@870ad8
    Could anyone please suggest how to type cast and use the return of valueChangeEvent.getNewValue() to get the selected values.
    Regards -
    Rohit

    Hi Timo -
    Thanks for the suggestion. I could get the values as below:
    public void multiOpUnitValChange(ValueChangeEvent valueChangeEvent) {
    // Add event code here...
    BindingContainer bindings = BindingContext.getCurrent().getCurrentBindingsEntry();
    DCIteratorBinding opUnitIter = (DCIteratorBinding)bindings.get("OperatingUnit2VOIterator");
    Integer[] values = (Integer[])valueChangeEvent.getNewValue();
    for (int i=0; i<values.length; i++){
    Row row = opUnitIter.getRowAtRangeIndex(i);
    System.out.println(row.getAttribute("OpUnitId"));
    Thanks -
    Rohit

  • How to get selected value from one choice list

    Hi All,
    i want to get selected value in onechoice list.how to achive this
    Regards,
    Smaran

    check these
    http://groundside.com/blog/DuncanMills.php?title=adf_the_list_binding_value_problem&more=1&c=1&tb=1&pb=1
    http://blogs.oracle.com/jdevotnharvest/2010/12/reading_the_selected_value_of_an_adf_bound_select_list_in_java.html
    http://www.oracle.com/technetwork/developer-tools/jdev/listbindingvalue-088449.html

  • Dvt:pivotFilterBar - how to get selected values from filter

    Hi all,
    I have a question: how to programmatically get selected values from pivot table's filter bar?
    I have tried to use
    pivotTable.getDataModel().getDataAccess().getValueQDR(startRow, startCol, DataAccess.QDR_WITH_PAGE);but for page edge dimensions it returns BAD DATA, it seems that it returns some cached values.
    Environment: JDev 11.1.1.3.0 without any patches.
    thanks,
    Miroslaw

    Hi,
    You can retrieve the selected value in the PivotFilterBar through the model of PivotFilterBar, instead of dataaccess:
    // get the model from the pivot filter bar instance
    QueryDescriptior queryDescriptor = (QueryDescriptor)pivotFilterBar.getValue();
    // retrieve a list of criterion, each one is used to populate each lov within the pivot filter bar
    ConjunctionCriterion conjunctionCriterion = queryDescriptor.getConjunctionCriterion();
    List<Criterion> criterionList = conjunctionCriterion.getCriterionList();
    for (int i=0; i<_criterionList.size(); i++) {
    AttributeCriterion criterion = (AttributeCriterion)criterionList.get(i);
    // _selected is the currently selected value
    Object selected = criterion.getValues().get(0);
    System.out.println(_selected);
    Hope that helps,
    Chadwick

  • EVS - how to get selected values back into model?

    Hi all!
    I am new to ‘WebDynpro’ but I’ve got a closer look to the tutorials but since I didn’t found a hint for my problem I try it this way! The situation is the following:
    I am using selector fields to support the user with some constants to choose from but it is still possible to enter the data directly into the input field.
    I followed the tutorial for this purpose with the difference that I initialized the selector fields with data coming from the model. This happens in the ‘wdDoInit()’ of the view controller.
    The problem is how to get the selected value back into the model without forcing the user to use the F4-Help or trigger a ‘onEnter’ event on the input field.
    Due to the modification of the data type at runtime I can’t bind the attribute of the view context holding the selected value to another one of a custom controller context.
    I hope there is a simple solution because I am just asking for a common functionality on a web site.
    Thanks in advance!
    Frank

    Reiner,
    I cannot fully understand your requirements, but probably my solution described in blog post <a href="/people/valery.silaev/blog/2006/03/10/minus-evs-plus-ovs-value-help-smart-input">Minus EVS, Plus OVS == value help + "smart" input</a> will help you.
    My idea was to use OVS instead of EVS with pair of calculated "proxy" attribute and real attribute. Real attribute has enumeration, proxy attribute used for input. In my solution real attribute is always synchronized with proxy attribute...
    Valery Silaev
    EPAM Systems
    http://www.NetWeaverTeam.com

  • How to get selected value from a listbox

    Hi !
    I use following code to fill in my LISTBOX with values :
    AT SELECTION-SCREEN OUTPUT.
      val-key = 1.
      val-text = '0016'.
      APPEND val TO list_values.
      val-key = 2.
      val-text = '0028'.
      APPEND val TO list_values.
      val-key = 3.
      val-text = '0035'.
      APPEND val TO list_values.
      val-key = 4.
      val-text = '2001'.
      APPEND val TO list_values.
      val-key = 5.
      val-text = '0515'.
      APPEND val TO list_values.
      CALL FUNCTION 'VRM_SET_VALUES'
        EXPORTING id     = 'p_list'
                  values = list_values.
    My question is - how to get a selected key/text value ? i dont need it to be done dynamically - i just need it in START OF SELECTION to perform tasks.
    Thx in advance.

    Unfortunetly it does not work
    i Define parameter as follows :
    PARAMETERS:
      p_list AS LISTBOX VISIBLE LENGTH 10.
    Then i add values to it :
    AT SELECTION-SCREEN OUTPUT.
      val-key = 1.
      val-text = '0016'.
      APPEND val TO list_values.
      val-key = 2.
      val-text = '0028'.
      APPEND val TO list_values.
      val-key = 3.
      val-text = '0035'.
      APPEND val TO list_values.
      val-key = 4.
      val-text = '2001'.
      APPEND val TO list_values.
      val-key = 5.
      val-text = '0515'.
      APPEND val TO list_values.
      CALL FUNCTION 'VRM_SET_VALUES'
        EXPORTING id     = 'p_list'
                  values = list_values.
    Then when i add a blank section :
    AT SELECTION-SCREEN ON p_list.
    I set a breakpoint in START OF SELECTION block - but the value is empty no matter what do i select.
    Actually when i select value from the list and hit enter key on selection screen the selection in a listbox goes empty :/
    Whats the cause of this ?
    Edited by: Jacek Zebrowski on Feb 26, 2009 12:38 PM

  • How to get selected-value of dropdown-field in alv ?

    Hello experts,
    I have a alv-table with dropdown-field.
    When I open the dropdown I am able to select another value.
    Now I use method ON_CLICK with  ON_CELL_ACTION, and when
    I change value in my alv, system jumps into this mehtod.
    But how do I get now the selected dropdown value in this method ?
    I use following code in comp-wdini in order to declare the dropdown:
    Dropdownfield
      DATA: lr_dp TYPE REF TO cl_salv_wd_uie_dropdown_by_key.
      DATA: lr_node TYPE REF TO if_wd_context_node_info.
      DATA: lt_valueset TYPE wdr_context_attr_value_list.
      DATA: ls_valueset TYPE wdr_context_attr_value.
      DATA : lr_nodeinfo TYPE REF TO if_wd_context_node_info.
      DATA  wa TYPE cdbc_tj30t.
      DATA: lr_drdn_by_index TYPE REF TO cl_salv_wd_uie_dropdown_by_idx.
      SELECT *   FROM cdbc_tj30t INTO wa WHERE stsma = 'CRMOPPOR' AND
        spras = 'DE'.
        ls_valueset-value = wa-estat. " actual values
        ls_valueset-text = wa-txt30. " text displaying on the dropdown
        APPEND ls_valueset TO lt_valueset.
      ENDSELECT.
      LOOP AT lt_columns INTO ls_column.
        CASE ls_column-id.
          WHEN 'CONCATSTATUSER'.
            CREATE OBJECT lr_drdn_by_index
              EXPORTING
                selected_key_fieldname = ls_column-id.
            lr_drdn_by_index->set_valueset_fieldname( 'VALUESET' ).
            lr_drdn_by_index->set_type( if_salv_wd_c_uie_drdn_by_index=>type_key_value ).
            ls_column-r_column->set_cell_editor( lr_drdn_by_index ).
         ENDCASE.
      ENDLOOP.
    In view-ini I fill the table which is bound to my alv-table:
    LOOP AT lt_list_opportunities INTO lstru_list_opportunities
          WHERE status = ls_opportunity_status-estat AND
         valid_to <= ls_input-bdate AND valid_from >= ls_input-vdate.
        ls_opportunities-valueset = lt_valueset.
        MOVE-CORRESPONDING lstru_list_opportunities TO ls_opportunities.
        APPEND   ls_opportunities TO ltt_list_opportunities.
      ENDLOOP.
      lo_nd_opportunities = wd_context->get_child_node( name =
      wd_this->wdctx_opportunities ).
      lo_nd_opportunities->bind_table( new_items = ltt_list_opportunities ).
    HOW can I now get the slected dropdown values in ON_CLICK with  ON_CELL_ACTION method ?
    Thanks for answers !!
    Gerd

    Hello Abap,
    when I have selected the value in the dropdown-box, then the event should start, and then I should have the
    selected values of the dropdown box.
    Hope you can help me !
    Gerd

  • How to move selected values in a table in one view to another

    Dear Experts,
    In my application,I have a table populated with data.My requirement is to select a row in the table and move the selected values of the row to the next view.
    Can anybody tell how to do this??
    Regards,
    Mamai.

    Hi mamai,
    First create a two internal tables ( nodes) itab1 & itab 2 with your required structure in component controller.
    Then bind the itab1 with view1 controller context.
    bind the itab2 with view2 controller context. and create a tables in both views and bind with itab1 and itab2 respectively.
    after getting the itab1 data, use the below code in wddoinit method of view2.
    data: count type i,
            pos type i value 1.
    Count = lo_nd_itab1->get_element_count( ).
    do count times.
    to copy the selected records
    if lo_nd_itab1->is_selected( index = pos ) = abap_true.
    lo_el_itab1 = lo_nd_itab1->get_element( index = pos ).
    lo_el_itab1->get_Static_attributes( importing static_attributes = ls_itab1 ).
    lo_el_itab2 = lo_nd_itab2->creat_element( ).
    lo_el_itab2->set_static_attributes( exporting static_attributes = ls_itab1 )
    lo_nd_itab2->bind_element( new-item = lo_el_itab2 set_initial_elements = abap_false ).
    endif.
    pos = pos + 1.
    enddo.
    Regards
    Srinivas

  • How to capture selected value from drop down by index

    Dear friends,
    i want to capture the value of select value from drop down by index, for eg if  select air france, how to capture , could any one please let me know
    Thanks
    Vijaya

    Hi Vijaya,
    You can get the value of selected from drop down as below
    Check out the event handler method attached to Onselect event of the ui element drop down by index , if no event is associated, then create an event and attach to the drop down list
    Now you will be having the CONTEXT_ELEMENT in the WDEVENT parameter
                   data lo_element type ref to if_wd_context_element.
                   lo_element = wdevent->get_context_element( name = 'CONTEXT_ELEMENT').
    Now, you can get the static attribute value of selected  drop down value & let us say your drop down list values are populated from context node 'ND_DRP_DOWN'
                   data ls_data type wd_this->element_nd_drp_down.
                             lo_element->get_static_attributes(
                                       importing
                                       static_attributes = ls_data ).
    Hope this helps you.
    Regards,
    Rama

  • How to display selected value in MessageChoice

    HI,
    I have a messageChoice on my Update screen. I need to display the selected value when the user comes to update the data on the screen. In the Process Request when i am printing the stmt
    System.out.println("The type of bean is PortletItemID::"+webBean.findIndexedChildRecursive("PortletItemID"));
    The output is The type of bean is PortletItemID:: OAFormValueBean
    How can i set the value that is coming from database in order to show the selected value in the message choice when the user is coming to the screen for updating the data.
    Thanks,
    Mohammadi

    Hi Tapash,
    In my case, i have mentioned the value in picklist View Definition ,picklist display attribute and picklist Value attribute. Where should i be providing my database value so that i can compare and display it as selected value.
    Thanks,
    Mohammadi

  • Drop-Down menu not retaining selected value

    I'm using LiveCycle Designer ES 8.1.1 with LiveCycle Forms and I render my forms in HTML.  When Google Chrome or Safari are the user's browser the drop-down menus do not retain their selected value when going from page to page.  For example I have a state drop-down on page 1.  The user selects Ohio and then continues on to page 2.  Then the user goes back to page 1 and the state drop-down now has Alabama selected.  If the user is on IE there is no problem.
    Any help would be much appreciated.
    Thank you
    Dennis

    hi...i would like to thank u for the help...the problem has already been resolved though..
    thanks,
    vitish

  • WAD: how to give selection values all together then execute report

    Hi,
    I have to made web report in BI 7. I am using 4 drop down box for Plant, Dist_chann, Year, Period.
    When I change any single value of any drop down box, query gets refreshed.
    But I want to give all selection values all together then if can provide a button "Go", so that query will be refreshed for those set of values. This will save time in execution.
    I tried with selection screen. Here I can give any set of values before execution.
    But Selection screen comes as a seperate screen. can I provide same selection screen in the same page of dash board, somewhere Top of dash board.
    Useful answers will definitely get full marks !!!
    Regards,
    Saurabh

    See the following document - https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/d0cb1cf2-6e84-2a10-c189-aafa2f04ac81
    This is an integrated planning document but it explains a way how query can be called only after values in dropdowns have been selected.

Maybe you are looking for

  • Issue with PO change output - Service line items

    Hi All, This is issue with PO change output. We have PO with line item 10, 20 and item 10 has 4 service line items. PO is approved and initial print out is taken. Some one goes and makes changes to 1st service line items of PO line item 10. A change

  • Can I import an existing topic page into a new topic page?

    I'm working in RH HTML 9 and am working on a project where there will be at least 2 versions of help documentation. One version for basic functionality, to be used by a novice user and another for advanced functionality, to be used by a advanced user

  • ITunes Sign In and Genius Wont Connect?

    Hey All, I have a repeating problem about my connection with Genius and signing in? It says there is an error and that I need to check my internet connection to see if it is active? I am using a modem, and I watch it connect right in front of my eyes

  • RSS Feed Rejected?

    RSS Feed: http://feed.podcastmachine.com/podcasts/9160/mp3.rss I had a topic a few days ago entitled, "Issue with Subscribing" Thanks to some immaculate help I found out that my RSS feed host server basically broke so I had to re-start from scratch.

  • Proportions of Still Images for HD

    A while back I asked on this forum the correct ratio/size to do still images for import into FCE. It was suggested to me to use 1440 x 1080 (and I also see this in the FCE export ( 1440 x 1080 16:9) so that is what I designed my Photoshop images to b