Selecting records in the table control

Hi Friends,
I have the requirement to be displayed in the table control, I got the data displayed in the table control. Now I need to select some of the records from the table control and update in the database. When I am trying to do that i am able to select only one records instead of some number of records. When I try to select the second record the first record which i selected is being unselected. Can any one tell me how to select more than one record in the table control.
Regards,
Line

hello,
to select more then 1 record
1> you need to put CHECK BOX FEILD
         or
1> you have to manually use control and select the feilds.
hope i have replied to your query
thankx
bhanu malik

Similar Messages

  • How to freeze the selection column in the table control of the module pool.

    hi ,
    in my module pool there is a row selection field  <b>w/selcolumn</b> of the table control called as mark.
    how to freeze the selection column where there is no record in the table control row.
    or in other words where wa is initial.
    thanks
    ekta

    Hi all,
    in the PBO of the screen the following code is written.
    say the selection column is MARK and is declared in the data as well.
    thanks
    ekta
    *************************C O D E **************************************************
    MODULE disp_tabctrl1 OUTPUT.
      IF flag_c = 1.
        READ TABLE it_create_data INTO wa_material_data
             INDEX tab_ctrl1-current_line.
      ELSE.
        READ TABLE it_material_data INTO wa_material_data
             INDEX tab_ctrl1-current_line.
        IF sy-subrc = 0.
          IF ok_code_0101 = '&SEL1'.
            mark = 'X'.
          ELSEIF ok_code_0101 = '&DSEL'.
            mark = ' '.
          ENDIF.
        ELSE.
          LOOP AT SCREEN.
            IF screen-name = 'MARK'.
              screen-input = 0.
              MODIFY SCREEN.
            ENDIF.
          ENDLOOP.
        ENDIF.
      ENDIF.
      index_t = tab_ctrl1-top_line.
      index_d = tab_ctrl1-top_line + n.
    ENDMODULE.                 " DISP_TABCTRL1  OUTPUT

  • Reading selected data in the table control

    Hi Friends,
    I have final data in my table control now the user wants to select only few records from the displayed data, for that I kept a check box for selection, But my question is I am unable to read the selected data.
    Actually user requirement is he has to update only the selected data from the displayed data in the table control.
    Can any one tell me how to read the selected records after displaying in the table control.
    Thanx in advance,
    Line

    Hi
    If your table control has a check box, your internal table should have a field for it. Its value will be X if the checkbox is setted else it'll be SPACE.
    So in the PAI u should read only the records where that flag is X:
    LOOP AT ITAB WHERE MARK = 'X'.
    ENDLOOP.
    Max

  • Selecting data in the table control

    Hi Friends,
    I have final data in my table control now the user wants to select only few records from the displayed data, for that I kept a check box for selection, But my question is I am unable to read the selected data.
    Actually user requirement is he has to update only the selected data from the displayed data in the table control.
    Can any one tell me how to read the selected records after displaying in the table control.
    Thanx in advance,
    Line

    Hello Line,
    As gopi has suggested do the following..
    for the table control properties u have an option called W/SelColumn.
    Give in some name (ROW_SEL)to that and also include a field CHK in the internal which is being passed to the table control.
    and in the PAI of the table control module wirte like this...
    Then in your code..
    PROCESS BEFORE OUTPUT.
    PBO FLOW LOGIC FOR TABLECONTROL 'TABCONTROL'
    MODULE TABCONTROL_CHANGE_TC_ATTR.
    MODULE TABCONTROL_CHANGE_COL_ATTR.
    LOOP AT lt_final
    INTO lw_final
    WITH CONTROL tabcontrol
    CURSOR tabcontrol-current_line.
    MODULE tabcontrol_get_lines.
    MODULE TABCONTROL_CHANGE_FIELD_ATTR
    ENDLOOP.
    MODULE status_0101.
    PROCESS AFTER INPUT.
    PAI FLOW LOGIC FOR TABLECONTROL 'TABCONTROL'
    LOOP AT lt_final.
    MODULE read_data.
    MODULE tabcontrol_user_command.
    ENDLOOP.
    MODULE TABCONTROL_CHANGE_TC_ATTR.
    MODULE TABCONTROL_CHANGE_COL_ATTR.
    MODULE user_command_0101.
    MODULE tabcontrol_user_command input.
    if lt_final-chek = 'X'.
    *put your logic here something like
    move corresponding lt_final to gt_final.
    *now you have selcted rows data in gt_final.
    endif.
    endmodule.
    Regards

  • How to find out the selected line in the table control

    Hi Guys,
    i have a requirement like this. i have table control and the internal table for that table control as IT_CASE. this internal table i declared as CHECKBX, MATNR, QUANTITY. but when i am enter the values in the table control i am getting the values in MATNR and QUANTITY in the that internal table IT_CASE. but when iam selecting that that line iam not getting CHECKBOX as 'X' in that internal table IT_CASE. i declared the table control as CAS_CONTROL and in that i have given the "w/selcolum" property as IT_CASE-CHECKBOX. now i want to fill that CHECKBOX as 'X' inthat internal table IT_CASE whatever the lines we are selecting only for those lines i want to fill up as 'X' in that internal table.
    Can you please suggest any one reg this.
    Thanks in advance
    Rahul

    Hello body,
    You can give a name such as 'SEL' in  w/selcol and declare SEL as char1. Then follow the coading.
    in TOP.
    data: sel type c.
    PROCESS AFTER INPUT.
    user_command_0011.
    loop at <Your internal table>.
    module get_data.
    endloop.
    Inside Module get_data.
        if sy-ucomm = <Your Fcode>
        if sel = 'X'.
           <Your internal table>-<Field for checkbox> = 'X'.
          append <Your internal table>.
        endif.
      endif.
    I think your issue is resolved.
    Regards.
    S Mahanta.

  • Copy selected lines in the table control

    Hi friends,
    I Have a screen 200 in which i have a button COPY and table control.
    In my table control i have 6 lines of data.
    now my requirement is when i select any lines  ie :  let us say i ahve selected 1 , 3 , 5 lines of my table control and when i click on the button COPY of that screen. i need those 3 selected lines 1 , 3 , 5 to be copied again in the table control
    example  :
    line 1         selected
    line2
    line3          selected
    line4
    line5          selected .
    line6
    now my table control should be
    line1
    line2
    line3
    line4
    line5
    line6
    line1
    line3
    line5
    How can i do that
    Regards
    Priyanka.

    I have similar issue...i need help how to accomplish automatic addition on every line.  example (see below)
    this is how it looks right now
    DATE    EMPLOYEE       DEPT JOB     LOT     OPER#     LX_HRS     OP_SETUP     LX_TYPE     COMPLETE
    2/23/2009     M.Paquiao   NB         1960     001     10             1.50                14.00                     S                      NO
    2/24/2009                                                      1.00             14.00                  S                        NO
    2/25/2009                                                      4.50                14.00                  S                    NO
    2/27/2009                                                      3.00             14.00                  S                        NO
    2/28/2009                                                      1.50             14.00                  R                       YES
    3/1/2009                                                      2.00             14.00                  R                  YES
    this what I need it to do when I meant automatic addition of each line:
    DATE   EMPLOYEE     DEPT     JOB     LOT     OPER#     LX_HRS     OP_SETUP     LX_TYPE     COMPLETE
    2/23/2009     M.Paquiao      NB        1960     001     10             1.50        14.00               S         NO
    2/24/2009                                                      2.50             14.00                  S             NO
    2/25/2009                                                      7.00        14.00                  S             NO
    2/27/2009                                                      10.00     14.00               S             NO
    2/28/2009                                                      11.50     14.00               R             YES
    3/1/2009                                                      13.50     14.00               R             YES
    As you can see everything is the same but on column LX_HRS, the first example one is not doing anything addition but on the second example is now doing addition.  This additions were done manually, how can I tell crystal to add each line, in the example above, the
    first example                                              second example: (addition is involved)
    date                lx_hrs                                  date                  lx_hrs
    2/23/09           1.50                                     2/23/09              1.50
    2/24/09           1.00                                     2/24/09              2.50 (sum of : 1.50 + 1.00 was added)
    2/25/09           4.50                                     2/25/09              7.00 (sum of 2.50 (on date 2/24/09 &  4.50 from date 2/25/09 of the first example).

  • Postion of data record in the table control

    Hi all,
    I am working on a module pool that has a table control which fetches the data from the Transparent table.
    Suppose there is data in the z-table formed and table control is showing the data record.
    i want to text boxes besides the table control, one of which will show me the value index of top row of the record set and other one will show me the value of last row appearing in that page of the table control.
    if i press page down then i should get new values in both the text boxes .
    please help me to get an idea what vales i will take to show the indexes.
    thanks
    ekta

    Thanks for you help.
    i have used a value 'n' which is no of rows that are on the one page of the table control.
    so when i do page down it will show me next values i.s values of the index currently on the table control next page.
    anyways thanks a lot

  • How to delete select data in the table control

      this problem makes me headache.
      I am new to labview, when  a table shows some data. many rows and column. how can delete on row which I selected. the other rows are remain no change.
    I really need help.thanks in advance. It is better to attach the program.my labview is 2009
    Solved!
    Go to Solution.

    Hi,
    You can do it with a table control as well. Check out the attached VI. To delete a row, Run the VI, just right click the row and click "Delete Row". To get back the default values, click reinitialize.
    Reards,
    NitZ
    (Give Kudos to Good Answers, Mark it as a Solution if your problem is Solved) 
    Attachments:
    Untitled 3.vi ‏8 KB

  • Variant for selection screen with the Table control entries in another Tab

    Hi Guys,
      The requirement is to create a variant for the two tabs on a selection screen.
      First tab contains the select options and the second contains table control for making entries.
      So will it be possible to create a variant when the user makes entries in the fields in one tab and the table on other tab?

    You wrote
    Utilizing the "Save as variant" option from the selection screen itself works out perfectly, but this variant cannot be transported.
    But, give the variant a name beginning with "CUS&" and this variant will be transported. Variant beginning with "CUS&" or "SAP&" are so-called "system variant" and are  transported automatically. You can then copy the transaction code and use this new variant in the new transaction.
    Regards,
    Raymond

  • Multiple record update in TABLE Control.

    Hi All,
    I m developing dialog program with table control.
    I want to know how to update multiple records through the table control if user selects more than one.
    Also depending on some condition i want to change the status of one reocrd and not the column as a display field and won't be editable. I have tried with loop at screen and modify screen, but it is showing the whole column as display only.
    ANy solution let me know

    Hi,
    pls chk this standard pgms.
    for examples on table control
    demo_dynpro_tabcont_loop
    demo_dynpro_tabcont_loop_at
    RSDEMO_TABLE_CONTROL
    chk a sample code.
    DATA :BEGIN OF int_table OCCURS 0,
           fld1 TYPE ztable-fld1,
            fld2 TYPE ztable-fld2,
            fld3 TYPE ztable-fld3,
            chk(1),
          END OF int_factor.
    *write the blow code in PAI
    LOOP AT int_table WHERE chk = 'X'.
    *modify the data base table
    MODIFY ztable FROM  int_table. "from header
    clear int_table
    ENDLOOP.
    regards
    Anver

  • Issue while  vertical scrolling in the table control

    Hi,
    i have my table control which can show 14 entries at a time. and i have almost 100 entries in table control.
    now if i selected 2 entries in the visible part.
    now scroll vertically.
    again come back to see the selected records now they are unselected.
    please respond soon.
    Thanks
    Malya

    Hi,
    I have redone the scenario and follow the steps it will work....
    STEP 1: Create an internal table with field for selection in table.
    STEP 2: Assign the selection field in the table control for the line selection.
    STEP 3: Now whenever the line is selected, the selection field will have a field 'X'.
    STEP 4: In PAI Modify the table fields those are selected with 'X'.
    STEP 5: Set a flag in PAI, flag = 'X'.
    STEP 6: In PBO set a condition .         " We set a flag so that we fetch the data only once.
    If flag NE 'X'.
    Fetch data.
    endif.
    Data:
          begin of ztable,
             ID type char4,
             Name type char30,
             Sel type c,
          end of ztable.
    PROCESS BEFORE OUTPUT.
      MODULE STATUS_0100.
      LOOP AT ITAB INTO FS WITH CONTROL EMP CURSOR W_I.
        MODULE UPDATE.
      ENDLOOP.
    PROCESS AFTER INPUT.
      LOOP AT ITAB.
      MODULE APPEND.
      ENDLOOP.
      MODULE USER_COMMAND_0100.
    INCLUDE YMODTOP                                 .    " global Data
    *&      Module  UPDATE  OUTPUT
    *       text
    MODULE UPDATE OUTPUT.
      MOVE FS TO FS.
    ENDMODULE.                 " UPDATE  OUTPUT
    *&      Module  STATUS_0100  OUTPUT
    *       text
    MODULE STATUS_0100 OUTPUT.
      IF FL_FLAG <> 1.
        SELECT * FROM ZTABLE INTO CORRESPONDING FIELDS OF TABLE ITAB.
      ENDIF.
    ENDMODULE.                 " STATUS_0100  OUTPUT
    *&      Module  append  INPUT
    *       text
    MODULE APPEND INPUT.
      MODIFY ITAB INDEX SY-STEPL FROM FS TRANSPORTING SEL .
      FL_FLAG = 1.
    ENDMODULE.
    Thanks&Regards
    Sarves

  • Data Display in the Table Control

    Hi All,
             Please help me know how to fetch the data from the internal table in to the Table Control.  I have defined the internal table with some fields and wrote the select query to fetch the records from database. But Iam unable to get the idea of how to pass the internal table records into the table control.
    Your suggestion will be appreciated.
    Thanks and Regards,
    Murali Krishna Tatoju

    HI
    if your select query is first operation before the screen is displayed.
    then write the select query in PBO.
    in PBO
    module select
    loop at itab with control tc.
    module transfer_itab_to_tc
    endloop
    in program.
    module select
    select query here and get the data.
    endmodule
    module transfer_itab_to_screen.
    move-corresponding itab to t_tab " here t_tab is strucutre from where the fields on Table control has been taken
    endmodule
    Cheerz
    Ram

  • How to use selection column in a table control

    I have given the name of the selection column to be 'DEF_SEL',now i want to select rows in the table control using the 'selection column attribute' and maniupulate it programmatically so that i would transport the rows selected using selection coulmn to a different table control.How would i do this?

    Hi raja,
      Once you have the table cobtrol built using the extra field in the internal table, all the selected rows will have DEF_SEL = 'X'.
    Now you can loop your internal table and filter the records which were selected.
    in pai modules:
    loop at itab where DEF_SEL = 'X'.
    Move itab information inrto another internal table.
    append itab_new.
    endloop.
    have another table control which shows the data in the itab_new.
    regards,
    Ravi

  • How can we delete a line from the table control .

    hi all
    how can we delete a line from the table control .
    situation is.
    created table control in se51 which will display the data of a table.
    how could i select a line from the table control ?
    how could i delete the selected lines form the table.
    thanks in advance

    Change the Table Control attributes such that user can only select a single record(row).
    <u>Tip to delete a selected record</u>
    1) write a module 'Mark' in the PAI as below
    PROCESS AFTER INPUT.
    MODULE cancel AT EXIT-COMMAND.
    LOOP WITH CONTROL table_view.
    MODULE read_table_control.
    FIELD flag MODULE mark ON INPUT.
    ENDLOOP.
    MODULE user_command_0100.
    2) Module Mark is below.
    MODULE mark INPUT.
    CHECK flag = 'X'.
    x = table_view-top_line + sy-stepl - 1.
    Delete itab INDEX x.
    ENDMODULE. " mark INPUT
    Table_view is the TableControl Name.
    'flag' is of type char(1) available in the Internal table which was assigned to the select option in the table control.
    <u>award if uesful</u>
    Regards,
    Sudheer

  • Adding an extra line in the table control

    Hi All,
    How can we add an extra record in the table control after the user hits ADD button?We tried doing it by incrementing the lines field in the table control,but it is executing the PBO part again after hitting the ADD button.Any SAP standard program will be helpful.
    Thanks,
    Rakesh.

    Hi,
    I think you can do that by inerting new line to Internal table that used in your Table Control. Here the sample:
    TC_DATA = Your Table Control
    IT_DATA = Your Internal Table used for Table Control.
    In your MODULE USER_COMMAND INPUT, add this code:
    IF OK_CODE = 'ADD'.
      CLEAR: IT_DATA.
      APPEND IT_DATA.
    ENDIF.
    Regards,

Maybe you are looking for

  • How get and edit xml code of BI Publisher Report

    Hi to all, I need to do some costumization to one BI Publisher report. Investigating I found a solution to do my costumization. However this requieres edit the xml code. Can you please let me know how can I get and edit this code? Thanks in advance r

  • How to make list item as text item  in oracle forms 6i

    Hello all, I created one form with one list item named "Country".. This list item shows country name for the particular employee in the employee table.I created this list item as database field. In the enter query mode i search an employee , This sho

  • Payment api issue on MIDlet Application

    Hi All, I am having an existing MIDlet application in which I want to implement payment api. I have followed all the guidlines provided by BB team. I have even done a sample application for payment api using UiApplication which is working fine, now w

  • Add to Favorites Toolbar Button

    I am trying to add a toolbar button (for webhelp output) for a client to use that will add the current page to the user's IE Favorites list. I have used the script from Rick Stone's Skinny On Skins "Toolbar button to add items to the Favorites list"

  • PDF does not show 2 nodes

    Hi I have a pdf where under the main node that is  bound to the inetractive form, I have placed two notes. Each note is of cardinality 0.n. The problem I have is the following: when the pdf is created, only the first subform with the first node is fi