Dropdown list in infotype table control

Hello,
I am creating a custom HR infotype with dropdown list field. This field holds a key but displays a text from text table. Dropdowns contents are dependant on Start Date of the infotype record and I am using PBO module to fetch this data. Everything works fine except one detail. Infotype has automatically generated overview table control, which holds various data including Start Date of infotype record and the dropdown field in question. And even that would work well if not for the date, in case when I drop the date check dropdowns in all rows get populated. Currently it seems to only use the date on the last row of the table control and subsequently fails to correctly populate dropdowns in all other rows. With no access to SAP code which populates table control, how do I get the date for each individual row?
Best regards, Armins

Hi Marty,
For this you have to create 2 nodes
1. A node which will be bound to the table. This will  be a singleton node.
2. A node for dropdown. This node should be inside the table node and should be a non-singleton one.
Check the singleton properties of both the nodes above.
Whenever you will create an element for table node, an instance of the dropdown node will be automatically created.
To set the value in this dropdown at leadselection, you can use the below logic
1. Assume you know the value of the fruit to be set in the dropdown
2. for(int i = 0; i < wdContext.nodeFruit().size(); i++)
          if( wdContext.currentTableNode().nodeFruit().getFruitElementAt(i).getFruit().equals(fruitName) )
                wdContext.currentTableNode().nodeFruit().setLeadSelection(i);
                break;
Hope this helps you.

Similar Messages

  • How to Populate a Dropdown field for a table control with different keys

    Hi All,
    I have Table control with abt eight columns (fields). Out of these eight field one field is with dropdown list. In table control Project ID is Primary key column. Depending upon this Project ID value, i have different values which is to be populated in dropdown boxes. In table control if there is only one project ID value say 'P000715' i can populate it but when i have more than one project ID (P000715, p000716, P000717.....) in display in rows of table control i want to have different values in my dropdown field corresponding to that row of project id. Experts please tell me how to achieve this functionality.
    Thankx in Advance
    Rizwan Ahmad Siddiqui

    The only way you may be able to do this is using
    MODULE PROCESS ON VALUE-REQUEST. User-programmer F4 help
    in your PAI routine.
    In this routine you would build the list and get the returned value to update the field.
    Something like this.
      DATA: BEGIN OF value_tab OCCURS 0,
        field1 TYPE zlmltype,
        field2 TYPE zltypex,
      END OF value_tab.
    * Drop down values
      REFRESH it_return_tab. CLEAR it_return_tab.
      REFRESH value_tab. CLEAR value_tab.
      SELECT ltype ltypex
        INTO TABLE value_tab
        FROM zlmltyp
        WHERE auth NE '9'.    "System Only
      CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
           EXPORTING
                retfield   = 'FIELD1'
                value_org  = 'S'
           TABLES
                value_tab  = value_tab[]
                return_tab = it_return_tab.
      READ TABLE it_return_tab INDEX 1 INTO wa_return_tab.
      CHECK sy-subrc EQ 0.
      p_pleadtyp = wa_return_tab-fieldval.

  • Highlight dropdown by index in table control in FPM error

    Hello,
    I have a situation where I would like to point out to a user that they have to maintain a value in a dropdown field in a table control. I am trapping the error situation in the Process_Event method of the FPM in my component,
    I would like to raise an FPM error to highlight this to the user. If I do this with a normal input field I can just pass the element and attribute that I want highlighting to the FPM error handler
    eg:
    wd_this->ao_fpm->mo_message_manager->report_bapiret2_message(
                                is_bapiret2 = ls_message-message_details
                                io_component = lo_component
                                io_element = ls_message-element
                                iv_attribute_name = ls_message-attribute_name ).
    and the field is highlighted and linked to the error.
    However, if the field is of a type dropdown by index, I can't seem to get it to highlight. I have tried passing the element that the dropdown text is bound to and the attribute/name of the text field, but this does not work. I even tried passing the child node name as the attribute, and the element as the parent element of the node holding the dropdown list - but unsuprisingly this doesn't work either.
    Is there anyway to highlight/link a dropdown by index field to an FPM error message - or is this functionality currently unsupported? Or perhaps I am making a simple mistake somewhere?
    Thanks for any suggestions!
    Cheers,
    Chris

    Chris Paine wrote:
    > Is there anyway to highlight/link a dropdown by index field to an FPM error message - or is this functionality currently unsupported? Or perhaps I am making a simple mistake somewhere?
    hi Chris,
    As far as i know this functionality is not supported.I have had the same problem earlier.

  • Problem when creating list box in table control

    Hi every body ,
                      I am placing a list box in table control ,  the list box is coming perfectly but
    when I am scrolling  or pressing enter the data in that field is clearing.
       if I remove the list box , and i enter the data directly and scrolling or press enter
    the data is not clearing.
    But only for list box only it is be having like that
    what is the problem?
      the code is as follows
    *{   INSERT         DEVK935807                                        1
    *&      Module  glaccuontlist  INPUT
          text
    module glaccuontlist input.
    type-pools vrm.
    tables: zglaccount.
    data:
            name  type vrm_id,
            list  type vrm_values,
            value like line of list.
           clear:value.
           refresh: list.
            name = 'ACGL_ITEM-HKONT'.
            select * from zglaccount.
             value-key = sy-dbcnt.
             value-text = zglaccount-hkont.
             append value to list.
             clear value.
            endselect.
          call function 'VRM_SET_VALUES'
            exporting
              id                    = name
              values                = list
          EXCEPTIONS
            ID_ILLEGAL_NAME       = 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.
    endmodule.                 " glaccuontlist  INPUT
    *}   INSERT
    thanks in advance.\
    srinivas.

    Hi srinivasa,
    try it.
    select * from zglaccount.
    <b>value-key = zglaccount-hkont.</b>
    value-text = zglaccount-hkont.
    append value to list.
    clear value.
    endselect.
    Regards
    Allan Cristian

  • How to Display a Calender upon clicking the dropdown list inside a table co

    Hi,
    I have a Listbox inside my table control and I need to Display a Calender upon clicking the dropdown list.
    Can any body help.
    Srinivas

    Hi,
    Try this:
    On your customizing screen,
    PROCESS ON VALUE-REQUEST.          
        Field T_ZT-SDATE
          module create_dateselect.
    In your main program:
    module create_dateselect.
    data:p_date like sy-datum.
    CALL FUNCTION 'F4_DATE'
       EXPORTING
         holiday_calendar_id = 'CN'                   
         display = ' '
       IMPORTING
         select_date = p_date
       EXCEPTIONS
         OTHERS = 4.
    t_zt-sdate = p_date.
    endmodule.
    Regards,
    Pole

  • Need help in creating a dropdown box inside a table control

    Hi,
    I need to display a calender upon click event of a dropdown box placed inside my table control.
    Can any body help me out.
    Regards,
    Srinivas

    Try this ex
    TYPE-POOLS VRM.
    VALUES-KEY = 'D'.
      VALUES-TEXT = 'Double Crate'.
      APPEND VALUES.
      VALUES-KEY = 'S'.
      VALUES-TEXT = 'Single Crate'.
      APPEND VALUES.
      VALUES-KEY = 'C'.
      VALUES-TEXT = 'Carton Box'.
      APPEND VALUES.
      VALUES-KEY = 'P'.
      VALUES-TEXT = 'Pallet'.
      APPEND VALUES.
      VALUES-KEY = 'W'.
      VALUES-TEXT = 'Wood.Case'.
      APPEND VALUES.
      VALUES-KEY = 'L'.
      VALUES-TEXT = 'Loose'.
      APPEND VALUES.
      CLEAR VALUES.
      CALL FUNCTION 'VRM_SET_VALUES'
         EXPORTING
           ID                    = 'CRTYPE'
           VALUES                = VALUES[]
        EXCEPTIONS
          ID_ILLEGAL_NAME       = 1
          OTHERS                = 2
    hope it helps..
    Edited by: prabhu p on May 22, 2008 10:55 AM

  • How can I use a Dropdown list in a table col and only get the choosen key?

    hi!
    I have chosen Cell editor = Dropdown for two of the columns in my WD table  (ordinary Table not ALV) .
    When the table is displayed the first time this looks OK, but if a user selects a value from the dropdown list, both the key and the explanation text is copied into the cell, and the cell column is automatically widened. I want to copy the key value only, and not the connected text. How is this possible?
    I started setting the table as fixed and setting the width on the column, but this was a puzzle I gave up since there are quite a lot of columns.
    regards, Tine

    Well , the problem is that in the dropdown list I want to see both the key value and the text, like you do in SAP GUI. Fex. if I would like to create a dropdown for langauges, factory calendar or countries, I want to see both the country code (the key) and the name of the country in the dropdown list, and then when user choose a line I would only like to see the keyvalue in the input field.  Right now I concatenate the key and the text into the 'value' in the valueset table.
    In some cases the user knows the key value better than the explanational text, and then it is good to show both values. But sInce I would like to save space in the table displayed in the view I only want to show the key values selected in the table (ex. NO if user choose Norway) .
    But maybe it is better to create this kind of input help as an OVS with no input fields .?

  • Adding a column in infotype(table control)

    i want to add a column in table control of infotype 0591. i need to add age for every nominee.
    i cant edit standard sap mp prog. so i thouhgt of copying it into zprogram, and now i have to assign it to that standard infotype so that this infotype will trigger my zmp program.
    any suggestions on this?

    Hi
    You cannot modify or copy the standard SAP generated program. Say if you wanted to add new field you could have done by doing the view deifnition for that infotype in tbale T582C or T582V. But since you want to add a new table control column i think you may have to create new infotype in PM01, else the std. functionality may be affected. You can check SAP help for creation of new infotypes.
    ~ Ranganath
    PS : Reward points for all useful answer !

  • Query on ABAP List Viewer and Table Control?

    Hi all,
    I was trying to solve the exercises in these areas....but was unable to do as some of the concepts were not clear to me as I'm new to this field.
    So Can any one help me out in giving me the Notes or attachments on the ABAP List Viewer(A.L.V.) and Table Control.
    My ID: [email protected]
    Waiting for a reply...
    A New Entrant in ABAP.
    Message was edited by:
            saikumar b

    Hi saikumar,
    I just start to work with Abap too. All links i Know:
    http://www.erpgenie.com/abap/controls/alvgrid.htm
    http://www.abapfans.hpg.ig.com.br/links.htm
    http://abap4.tripod.com/index..html
    http://paginas.terra.com.br/educacao/abap/
    http://www.sdn.sap.com/
    http://www.sap-img.com/
    http://www.planetsap.com/Tips_and_Tricks.htm
    http://www.abap4.com.br/
    http://www.erpgenie.com/sap/abap/index.htm
    Good lucky

  • Dropdown list error - in table

    Hi,
    I�m trying to make a table with different fields, with one database. For example:
    Name product Number of products
    So i want to put in the number of products�s a dropdown list. For example, if the product chocolate has 6 units, in the dropdowlist may appear 1-2-...6 and i will select what i want. The database has a field withs these fields.
    So, what i have done is this:
    private void vinos(){
       int noofDBRows = vinosDataProvider.getRowCount();
       listOptionsVinos = new Option[noofDBRows + 1];
       int rowcount = 0;
       if (noofDBRows > 0) {
           // Build the Options Array with the data
           // from DataProvider plus Dummy Value
          vinosDataProvider.cursorFirst();
          do{
              String linea=vinosDataProvider.getCursorRow().getRowId(); 
              int aux=Integer.parseInt(vinosDataProvider.getValue("nUds").toString());
           for (int i=0;i<aux;i++){
                String i2=String.valueOf(i);
               listOptionsVinos=new Option(i2);
    } while (vinosDataProvider.cursorNext());
    // Add Dummy Value to Array at the end,
    // Use Dummy Value ("999") as Value for the Dummy!!
    // Note : - You could add the Dummy value at
    // any position of your choice
    listOptionsVinos[rowcount] = new Option("999", "-------");
    } else {
    listOptionsVinos[rowcount] = new Option("999", "No Rows from DB");
    } public void init() {
    vinos();
    }I have based in this page:
    http://www.netbeans.org/kb/55/dropdowncomp.html
    I know that it is erroneous because the listOptionVinos is common for all the rows, so if anyone could help me i will be pleased.
    Thanks you very much!
    *if anyone understand spanish please say to me because i�ll explain better.
    *si alguien entiende espa�ol que me diga y le intentare explicarselo mejor.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

    Hi, again!
    The two columns are from the same table, yes. Here is an example of the database:
    Name number
    chocolate 3
    In the db only appear the number 3, so what i want is that in the dropdown appear numbers from 0 to N, in this case 3. So i will choose the number what i want. To do this, i have done a function in mysql which functionalitty is to return numbers from 0 to N. So if i send the number 3, it must send numbers from 0 to 3.
    After that, to prove it, I have created a new one dropdown sending a random value to the procedure. But when i run it, the dropdown doesn`t show anything. This is the code that i have done:
    public SessionBean1() {
    public void init() {
            a3();
    public void a3(){
            try{
                String num="3";
                cantidadRowSet.setCommand("CALL sp_NumberList(?)");
                cantidadRowSet.setObject(0,num);
               cantidadDataProvider.refresh();
               int noofDBRows = cantidadDataProvider.getRowCount();
              opcionesprueba2 = new Option[noofDBRows+1];
               int rowcount = 0;
               if (noofDBRows > 0) { 
                cantidadDataProvider.cursorFirst();
               do {
               opcionesprueba2[rowcount] = new Option(cantidadDataProvider.getValue("1").toString());
               rowcount++;
                while (cantidadDataProvider.cursorNext());
                opcionesprueba2[rowcount] = new Option("999", "---------");
                }else{
            opcionesprueba2[rowcount] = new Option("999", "No Rows from DB");
            }catch(SQLException e){}
       }Thank you very much

  • List box for table control

    Hi,
    I need a list box for an input field in table control.
    In brief. I have 5 fields in table control out of which i have to enter values manually for 1 field and for 1 field i need a list box or drop down and then when i press enter the remaining fields should be populated.
    i got the code working but now they need the drop down list for the second input field.
    If anybody could provide with the code it would be real helpful and  iwas confused whether i need to write code in pov or some where else.
    the field for which i need list box is taken from dictionary .
    any help would be geatly appreciated.
    suchitra

    Refer this link:
    table control Drop down list
    Regards,
    ravi

  • DropDown by Index in table control

    Hi,
    I'm using dropdown by index(i need different values for each row) in my table control and I have this problem:
    I have this context binded to my table control:
    TABLE_NODE (card. 0..n)
       - ATRIB1
       - ATRIB2
       - DROPDWN_NODE (card. 0..n sel. 0..1) - to this node dropdown by index is binded
            - VALUE
            - TEXT     <-- bind this attribute to Texts property
    Dropdown is filled OK, but how to transfer selected dropdown value to ATRIB2? And then, if I have a value in ATRIB2, how to diplay correct text for user in dropdown?
    Another thing is that I have 2 dropdowns by value in table and values of second depends on selected value in first. How should I refresh second dropdown by index when user change value in first?
    Many thanks for reply.

    I'm also facing the issue.  Can u plz. share the source code.

  • Problem with list box in table control (Module pool) .

    Hi,
    I'm facing a problem while populating values in List Box..
    While I'm clicking a value from the list box it is not being hold in that box...box got blanked.
    Please help me to solve this.

    process before output.
    module pop_drop_down.
    module pop_drop_down output.
      name1 = 'IO5'.
      REFRESH list1.
      LOOP AT it_zpoitshead INTO wa_zpoitshead.
        value1-key = wa_zpoitshead-createdt.
        value1-key = wa_zpoitshead-its_ebeln.
        APPEND value1 to list1.
      ENDLOOP.
      CLEAR value1.
      CALL FUNCTION 'VRM_SET_VALUES'
        EXPORTING
          id                    = name1
          values                = list1
       EXCEPTIONS
         ID_ILLEGAL_NAME       = 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.
    endmodule.                 " pop_drop_down  OUTPUT

  • Dropdown list in tab srtip

    Hi,
      I have created a text box for dropdown list in my table control.I have used the FM 'VRM_SET_VALUES to get the values.The name of the text box is 'LISTBOX' and the FCODE is also stated.In the user command do i have to check the contents of the textbox string for each and every value of the list and select the corresponding data for each value to filter the table according to it or is there any other method to check the condition?

    Hi,
      I have created a text box for dropdown list in my table control.I have used the FM 'VRM_SET_VALUES to get the values.The name of the text box is 'LISTBOX' and the FCODE is also stated.In the user command do i have to check the contents of the textbox string for each and every value of the list and select the corresponding data for each value to filter the table according to it or is there any other method to check the condition?

  • How to implement two dependent dropdown lists in an input  table row?

    Hi all,
    I am new in Jdev 11g. I try to develop an input table with two dependent dropdown list. I can create independent dropdown list in such table. When I try to implement dependent one following some examples do it in a form using bind variable in the view object I get an empty listbox. How can I do this? Is it possible. I cannot find any documents about this.
    Thanks in advance

    Hi,
    it hasn't changed between 10.1.3 and 11. The basic outline of how you do it is
    - use a managed bean to query the data
    - populate the list with f:selectItems that point to the managed bean ArrayList<SelectItem> for the master and the detail
    - obtain the master ID in the managed bean by parsing the #{row} variable when the table renders
    - then bulild the detail list
    - have the detail list referencing the ArrayList<SelectItem> you expose for the details
    Note that without proper caching, the action is quite expensive
    Frank

Maybe you are looking for

  • Importing Service Invoices with description in document line

    Hello, I am importing service invoice but also want the put in the description. I don't know which field i need to use for the description. Below you see 1 line, it import oke but without the description field. document_lines RecordKey     AccountCod

  • MIRO of Custom duty in case of  Assets

    Dear Sir, While posting of MIRO for custom duty i(Planned delivery cost(n account assigned assets for non valuated material sytem is posting value as Vendor account credit Asset account debit my asset is debited by total custom duty including CVD ,EC

  • Display/Change/Delete of planning object not working in BPS

    Hi Guys While displaying or changing object in planning workbench, system is taking too long to process the request and request doesn't completes even in hours. The following operations are not working 1. Delete Planning Area/Level. 2. Display/Change

  • HT1296 Updates to my calendar on my iPad do not update my calendar in Outlook 2003.

    When I sync the updates I have made to the calendar on my iPad do not get put into my calendar on my PC.

  • MM01 Error - Accounting View

    Hi All When i create a Raw Material in Industry Sector      :      Mechanical Engineering Material Type        :       Raw Material(ROH) System throws an error " Please Enter Moving average for this material" Please Suggest Regards Jagadish