Selecting multiple rows in a table

Hi All,
I have one problem with selecting multiple rows in a table.I tried with setting table property-selectionMode as Multi, but i dinn't get the solution.
please provide me solution for this.
Thanks & Regards,
Sreelakshmi.

HI
Int leadSelection = wdcontext.nodemodelnode.getLeadSelection();
  for(int i=0;i<wdcontext.nodeModelNode.size;i++)
    if(wdcontext.nodeModelNode.isMultiselected(i) || leadSelection ==i)
           String name = wdcontext.nodemodelnode.getnameelementatindex(i).getName();
           String  address = wdcontext.nodemodelnode.getaddresselementatindex(i).getAddress();
           String age = wdcontext.nodemodelnode.getAgeelementatindex(i).getAge();
        Create a method for the Table Property onLeadSelect() where you can open a popup window
         Create a value node and with attributes same as Table attributes and then set the values of the table
         to the value node attributes.
Thanks

Similar Messages

  • Select multiple rows from dual table

    Is it possible to select multiple rows from dual table using a single select statement.
    i.e., i want the out put to be
    column_name
    1
    2
    3
    4
    Edited by: vidya.ramachandra on Dec 14, 2009 8:24 AM

    Aside from the fact you're responding to an old thread...
    1002424 wrote:
    While using CONNECT BY, I see it always leave behind one row.
    Suppose I have a condition based on which I have to generate constant rows like
    SELECT 1 FROM DUAL WHERE ROWNUM < N;
    Here if N = 0, still it gives out single row.... you are obviously doing something wrong in your code elsewhere, because that SQL statement does not always return a single row...
    SQL> SELECT 1 FROM DUAL WHERE ROWNUM < 0;
    no rows selected
    SQL>

  • Selecting multiple rows of a table

    Hi Forum,
    How to select multiple rows of a table at a time? Please help me..
    Thanks
    Swapna

    Hi Swapna,
    To select more then one row in table, just set the selectionmode property of table to 'multi' or 'auto' and also change the selection property of the node (to which table is binded) to  0:n.
    I hope it helps.
    Regards
    Arjun
    Edited by: Arjun on Feb 4, 2009 11:52 AM

  • Select Multiple Rows in a Table without CTRL

    Expecting the user to press "Ctrl" when selecting multple rows is very unfriendly and unintuitive. We'd like the row selection to work as in ALV where you just select multiple rows by clicking on them.
    We've set the tables rowSelectable to true and selectionMode to 'multi' but we still cannot select multiple rows without the CTRL hotkey.
    This issue apparently [arose before|About selection in the table] but wasn't resolved.
    System Details
    SAP_ABA     701     0006     SAPKA70106
    SAP_BASIS     701     0006     SAPKB70106
    SAP_AP     700     0019     SAPKNA7019

    Hello Marc,
    you need to call IF_WD_CONTEXT_NODE->set_selected(index = lv_index) sorry for the typo in my previous comment.
    by calling IF_WD_CONTEXT_NODE->set_selected method wont remove the lead selection.
    to unselect the records, you can call the same method by passing the FLAG value as abap_false.
    so for your usecase the logic will be like this in the ON_SELECT event handler
    1. get the index of the new_lead_selection
    2. check whether this is already seleted in the context node by calling IF_WD_CONTEXT_NODE->IS_selected
    3. if already selected then call IF_WD_CONTEXT_NODE->set_selected( flag = abap_false index = lv_index)
       if not selected then call IF_WD_CONTEXT_NODE->set_selected( index = lv_index )
    Hope this solved your problem.
    BR, Saravanan
    Edited by: Saraa_n on Jul 6, 2011 11:52 AM

  • Select multiple row in a table that are not connected

    I want to be able to select multiple rows, but want to be able to select rows that are not next to each other. They maybe have one or two rows between. Is there anyway to do this in a table?
    Thanks

    So do a lot of other people, but you can’t.
    Tell Adobe here: https://www.adobe.com/cfusion/mmform/index.cfm?name=wishform
    Bob

  • IlleagalAurgumentException while selecting  multiple rows in  a table

    hi
    i am facing the problem with the adfTable selection.when i select more number of rows or selecting the rows fastly some time key set becomes null and also giving IlleagalAurgument Exception. i am giving the code i am using below
    List tableData=(List)table1.getValue();
    Iterator it=table1.getSelectedRowKeys().iterator();
    while(it.hasNext()) {
    Integer keyStr =(Integer) it.next();
    System.out.println(" selected key ===="+keyStr);
    if(keyStr!=null)
    selectedList.add((FinalCurriculumStrands)tableData.get(keyStr));
    keystr should not become null when there are selected rows.but it is coming as null.because keystr is null i am unable recover selected rows.please give me the solution.

    duplicate: af:adfTable Selection issue

  • Reg Selection of  Multiple Rows in a Table

    Hi all,
    I have to select multiple rows from a table and have to display those selected records in another table in the next screen.
    The problem is, when I am selecting the records in a table, selection should not be allowed on some records based on a condition. Is it possible with the default selection mode of webdynpro. If so, Please tell me how can we disable the selection of certain records in a table(using the default selection mode provided by webdynpro)
    Else, if we have to use check boxes for selection(in case of my problem), please do help me out in how to disable the selection of certain records in a table(using check boxes for selection).
    Please help me out. Its urgent...
    Reward points guranteed.
    Regards,
    Murthy.

    HI Narayana,
    Multiple selection  property is specific to a table, not for a tableElment(ie. for a row), so u cant set some of the rows as multi selected and some as node
    U can use Checkbox for this purpose. Based on the condition u can make the check box as enabled and disabled
    To achieve this, Create 2 boolean variables inside table node, one for checkbox value(Let it be <b>CBValue</b> .Bind this to checked property of Checkbox) and other for enabling and disabling Checkbox(Let it be <b>CBReadOnly</b>. Bind this to readonly property of CheckBox).
    At the time of creation of table elements, as per the condition, u can control the selection as
    IPrivate<View>.I<Table>Node tNode=wdContext.node<Table>();
    for(int i=0;i<5;i++)
    IPrivate<View>.I<Table>Element tEl=tNode.create<Table>Element();
    tNode.addElement(tEl);
    tEl.setCBValue(false);//Unchecking Checkboxes initially
    if(condition=non selectable)
      tEl.setCBReadOnly(true);
    else
      tEl.setCBReadOnly(false)
    Regards
    Fahad Hamsa

  • How to select multiple row of table using check box?

    hi,
             i am having table on view having first field as checkbox. what i want, when i click on checkboxes in multiple rows, and i click on any button i need to use those content to next view...
              my problem is if i select only one row , i can use onlead select property of table..but when i select multiple rows  through check box how should i read contents of table....?
    Plz solve it.
    Thanks,
    Saurin Shah

    Hello Saurin,
    You are right using LeadSelection you can select only 1 row at a time. You will have to make use of Selection for achieving this. First you will have to change the selection mode of the table to multiple & also change the selection property for the related context to 0..n . Please find a code extract which might help you. (However this facility is only available from SP 14.) The main part is using the set_selected method of if_wd_context_node.
    data: node_zcourse_details type ref to if_wd_context_node,
             node_course_assign type ref to if_wd_context_node,
             elem_course_assign type ref to if_wd_context_element,
             stru_course_assign type if_v_details=>element_course_assign ,
             item_popin_selected like stru_course_assign-popin_selected.
    "     navigate from <CONTEXT> to <ZCOURSE_DETAILS> via lead selection
    node_zcourse_details = wd_context->get_child_node( name = if_v_details=>wdctx_zcourse_details ).
    "     navigate from <ZCOURSE_DETAILS> to <COURSE_ASSIGN> via lead selection
    node_course_assign = node_zcourse_details->get_child_node( name = if_v_details=>wdctx_course_assign ).
    "     @TODO handle not set lead selection
    if ( node_course_assign is initial ).
    exit.
    endif.
    data elem_set type wdr_context_element_set.
    field-symbols <wa_elem> like line of elem_set.
    elem_set = node_course_assign->get_elements( ).
    loop at elem_set assigning <wa_elem>.
       <wa_elem>->set_selected( TRUE OR FALSE ). " Supply either TRUE/FALSE in here
    endloop.

  • How to select multiple rows from List Of Values

    Hello,
    I use ADF 11g to create my list of values (LOV). I want to select multiple rows from it. but i can't.
    so how i can select many rows to set them in my adf table.
    Thank in advance

    Hi,
    LOV is map to an attribute in the viewObject so it will return only one value or more values from selected row. You can't select multiple rows from LOV.
    But you can do this by using popup which you can select multiple rows and insert the selected rows to another table.
    This blog post explain how to achieve this :
    http://husaindalal.blogspot.com/2009/11/search-from-popup-and-add-to-new-table.html#comments
    Sameh Nassar

  • Get Multiple Rows into internal Table using Webdynpro Alv Display ..

    Hi guys ,
    I need to find out the logic for getting all the selected rows into the internal table.
    When i display the ALV Output on webdypro screen .
    USer Selects multiple rows for further processing ..
    Ineed to get all the rows selected by user into an internal table .
    Please let me know how to achive this ...
    Thanks in advance for quick reply
    Regards
    Saurabh Goel

    Hi,
    You need to use the method GET_SELECTED of IF_WD_CONTEXT_NODE to get the rows selected. Also ccheck for the paramters of that method, this retruns the element set.
    This meets your requirement.
    Regards,
    Lekha.

  • Inserting Multiple Rows in a table

    Hello,
    I need to insert multiple rows in a table with the selected items from a list (Multiple select).
    How do i go about it. I'm using ADF-struts-UIX application on Jdeveloper 9.0.5.2
    Thanks.

    Jonas, I've downloaded the sample application from your ADF UIX Editable table tip but have some problems.
    I can't even open the emp.table.uix file - errors are:
    Parsing error. Unable to parse binding.
    javax.servlet.jst.el.ELException:Function ctrl:createSortableHeaderModel was not found.
    and
    javax.servlet.jst.el.ELException:Function ctrl:getSortOrder was not found.
    Also - is there a place in the sample where you define the sample tables? They do not seem to match the standard sample emp table, for instance.
    I've just started using JDeveloper and would like to use the solution.
    Thanks - Linda

  • Updating multiple rows in a table in ADF

    Hi
    How do we update multiple rows in a table.
    Onclicking a update button the changed rows must be updated.

    Hi Prince,
    currently I am selecting one row from the table and rendering a region at the top of the table and capturing the user entered data with the following code:
    ViewObjectVOImpl vo = getViewObjectVO1();
    Row CurrentRow = vo.getCurrentRow();
    //After this I perform the checks like user entered value is not null or check input as per business logic.
    if(CurrentRow.getAttribute("attributeName") ==null){
    //Add what message you want to display
    //Add other business logic.
    After making all the checks, i commit it.
    getOADBTransaction().commit();
    Now in my new page I am capturing the user input in the table itself like an excel sheet. Suppose there are ten rows in my advanced table on my page, and each row has one editable field. I have one save button at the bottom of the table.
    Now on clicking the save button I have to capture the user input, check whether there is any null value and if all the entered data is correct then only I should commit it.
    Can you please let me know how we can accomplish that.
    Regards
    Hawker

  • Easy Question:Select many rows from a table and execute BAPI for these rows

    Hi Experts,
    I have created one WD project. The WD project fetches some records of backend using BAPI and displays in a table. I have to select some rows from the table and then execute BAPI for selected rows.
    How I can select multiple records from the table and then execute another BAPI for selected rows.
    Regards,
    Gary

    Hi,
    In the Node which you binded to the table create one more attribute of type boolean.
    For example your node is as below:
    //Table Node
    TableNode
    > Att1
    > Att2
    > isSelected(boolean) - Newly created attribute for this requirement.
    //Result Node contains the elements selected in TableNode
    ResultNode
    >Att1
    >Att2
    Now in the table create one more Column with Checkbox as tablecell editor. Now bind this boolean attribute to that check box.
    Now in the code you can get the selected rows by user as below:
    for(int i=0;i<TableNode().size();i++)
      if(wdContext.nodeTableNode().getTableNodeElementAt(i).getIsSelected()==true)
        IPrivateTestView.IResultNode element=wdContext.createResultNodeElement();
        element.setAtt1(wdContext.nodeTableNode().getTableNodeElementAt(i).getAtt1());
        element.setAtt2(wdContext.nodeTableNode().getTableNodeElementAt(i).getAtt2());
       wdContext.nodeResultNode().addElement(element);
    Regards,
    Charan

  • Selecting multiple rows using column header with checkbox in it.

    Dear All.,
    I am trying to select multiple rows with checkbox in column header but it doesnot works...
    Following is my codel
    <af:table value="#{bindings.xx.collectionModel}"
                          var="row"
                          rows="#{bindings.xx.rangeSize}"
                          emptyText="#{bindings.xx.viewable ? 'No data to display.' : 'Access Denied.'}"
                          fetchSize="#{bindings.xx.rangeSize}"
                          rowBandingInterval="1"
                          filterModel="#{bindings.xx.queryDescriptor}"
                          queryListener="#{bindings.xx.processQuery}"
                          varStatus="vs" partialTriggers="sbcSelectAll sbcChkFlag"
                          selectedRowKeys="#{bindings.xx.collectionModel.selectedRow}"
                          selectionListener="#{bindings.xx.collectionModel.makeCurrent}"
                          rowSelection="none" id="tCdMast" width="400"
                          columnStretching="column:c4" inlineStyle="height:200px;">
                  <af:column sortProperty="ChkFlag" filterable="true"
                             sortable="true"
                             headerText="#{bindings.xx.hints.ChkFlag.label}"
                             id="c2" width="55"
                             inlineStyle="#{row.ChkFlag ? 'background-color:#9CACC9;' : ''}">
                    <af:selectBooleanCheckbox simple="true" value="#{row.ChkFlag}"
                                              selected="#{row.ChkFlag}" id="sbcChkFlag"
                                              autoSubmit="true" immediate="true"/>
                    <f:facet name="header">
                      <af:selectBooleanCheckbox simple="true"
                                                autoSubmit="true"
                                                valueChangeListener="#{xxBean.onTableChkAllCheckChanged}"
                                                id="sbcSelectAll"/>
                    </f:facet>
                  </af:column>
    </af:table>
    Managed Bean
        public void onTableChkAllCheckChanged(ValueChangeEvent valueChangeEvent) {
            Boolean newValue =
                Boolean.valueOf(u.nvlString(valueChangeEvent.getNewValue(),
                                            "false"));
            Boolean oldValue =
                Boolean.valueOf(u.nvlString(valueChangeEvent.getOldValue(),
                                            "false"));
            if (newValue.equals(oldValue))
                return;
            int rowIndex=0;
            ViewObject vo = u.findIterator("xxIterator").getViewObject();
            vo.reset();
            while(vo.hasNext()){
              Row row;
              if(rowIndex==0)
                  row=vo.first();
              else
                  row=vo.next();
                 row.setAttribute("ChkFlag", newValue.booleanValue());
              rowIndex=1;
            u.addPartialTargets(tableDocuments);
        }Please help!!.
    Thanks & Regards,
    Santosh.
    jdeve 11.1.1.4.0

    Can you check this sample in the blog post?
    http://sameh-nassar.blogspot.com/2009/12/use-checkbox-for-selecting-multiple.html
    Thanks,
    Navaneeth

  • Selecting Multiple Rows from ALV GRID Display

    Hi,
    I am having a ALV GRID Display. I want to select multiple rows from the Output and move them to an internal table.
    Please let me know how do I acheive this.
    Thanks in advance,
    Ishaq.

    Hi,
    Have a look on the following code. It displays the selected rows which hv been selected in basic list.
    TABLES:
      spfli.
    TYPE-POOLS:
      slis.
    DATA:
      BEGIN OF t_spfli OCCURS 0,
        checkbox.
            INCLUDE STRUCTURE spfli.
    DATA:  END OF t_spfli.
    DATA:
      t_sspfli LIKE STANDARD TABLE OF t_spfli .
    DATA:
      fs_spfli LIKE LINE OF t_sspfli.
    DATA:
      fs_layout TYPE  slis_layout_alv,
      w_program TYPE sy-repid.
    SELECT *
      FROM spfli
      INTO CORRESPONDING FIELDS OF TABLE t_spfli.
    *fs_layout-info_fieldname = 'COLOR'.
    fs_layout-box_fieldname = 'CHECKBOX'.
    w_program = sy-repid.
    CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
      EXPORTING
        i_callback_program       = w_program
        i_callback_pf_status_set = 'FLIGHT'
        i_callback_user_command  = 'SPFLI_INFO'
        i_structure_name         = 'SPFLI'
        is_layout                = fs_layout
      TABLES
        t_outtab                 = t_spfli
      EXCEPTIONS
        program_error            = 1
        OTHERS                   = 2.
    IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    *&      Form  FLIGHT
          text
         -->RT_EXTAB   text
    FORM flight    USING rt_extab TYPE slis_t_extab..
      SET PF-STATUS 'FLIGHT' EXCLUDING rt_extab.
    ENDFORM.                    "FLIGHT
    *&      Form  SPFLI_INFO
          text
         -->UCOMM      text
         -->SELFIELD   text
    FORM spfli_info USING ucomm LIKE sy-ucomm
                           selfield TYPE slis_selfield.
      selfield-refresh = 'X'.
      CASE ucomm.
        WHEN 'FLIGHT'.
          LOOP AT t_spfli.
            IF t_spfli-checkbox = 'X'.
              t_spfli-checkbox = ' '.
             t_spfli-color = 'C51'.
              MODIFY t_spfli TRANSPORTING checkbox.
              fs_spfli = t_spfli.
              APPEND fs_spfli TO t_sspfli.
            ENDIF.
          ENDLOOP.
        WHEN 'EXIT'.
          LEAVE PROGRAM.
      ENDCASE.
      CLEAR fs_spfli.
      fs_layout-info_fieldname = 'COLOR'.
    fs_layout-confirmation_prompt = 'X'.
      fs_layout-key_hotspot = 'X'.
      CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
        EXPORTING
          i_callback_program = w_program
          i_structure_name   = 'SFLIGHT'
          is_layout          = fs_layout
        TABLES
          t_outtab           = t_sspfli
        EXCEPTIONS
          program_error      = 1
          OTHERS             = 2.
      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 t_sspfli.
    ENDFORM.                    "SPFLI_INFO
    Regards,
    Chandu

Maybe you are looking for

  • 'Printhead Problem' on week-old HP Officejet Pro 6830

    I purchased a HP Officejet Pro 6830 for around $130 only a week ago to be used at home for my study requirements. I was anticipating that this printer would be reliable and, for the price tag, last me a little over a week.. Unfortunately 7 days after

  • Browser Hangs iFbA in Web Dynpro Abap

    Hi Support, I'm developing an Abap Web Dynpro with Adobe Interactive Form inside. I have setting these parameters: InteractiveForm.enabled = true, InteractiveForm.readonly = false. Web Dynpro Page open correctly with iFbA but when I click one button

  • Adobe Acrobat Reader 8.1 just quit working.

    I can't create a PDF document through the print menu.  No longer able to print documents I previously created with the program.  When I open the progam, it automatically closes within a few seconds.   Error message received when I try to either print

  • Using Copy Express for transfering Chart Of Accounts

    Can any one tell me how to use Copy Express Add-On And also how to save the xml. file of exiting database template and upload into new database. thanx in advance.

  • My Hands On iPad 2 WiFi/3G 64GB

    Helo folks Finally my ex wife came back and bought me the above described pad, its pretty good though still the original rocks as john lennon, anyways i have noticed something, now I have 3 ipads, 2 of them first generation and the last one is the la