Grouping of two rows of internal table

Hi all,
I am having a requirement in which I want to group two rows of an internal table and assign a pointer to the two rows.
This pointer variable will then be passed to ALV.
Help reqd.
regards.

Hi Gaurav,
Hope the below code helps:
TYPES :BEGIN OF TY_ITAB2,
DATA(400),
END OF TY_ITAB2.
DATA: ITAB3 TYPE TY_ITAB2 OCCURS 0 WITH HEADER LINE
Loop at itab1.
ITAB3-DATA = ITAB1-LABEL.
APPEND ITAB3.
ITAB3-DATA = ITAB1-MATNR.
APPEND ITAB3.
endloop.
                    or
You can create a deep internal table. You can declare one Column as an internal table and store the NOTES in that Internal table for each row.
http://help.sap.com/saphelp_nw04/helpdata/en/fc/eb366d358411d1829f0000e829fbfe/content.htm
you can check the example in the link
Kindly Reward Points If You Find The Reply Helpful.
Cheers,
Chaitanya.

Similar Messages

  • Determine Number of  rows in Internal Table

    Hi,
      I have defined my internal table as follows:
         TYPES : BEGIN OF ABC_KEY,
                  FIELD1(2)   TYPE C,
                  FIELD2(1)   TYPE C,
                  FIELD3(8)   TYPE N,
                  END OF ABC_KEY.
    DATA: itab1 TYPE TABLE OF ABC_KEY
                      WITH KEY FIELD1,
           wa_lines_1 LIKE LINE OF itab1.
    How can I retrieve the number of rows in Internal Table?
    Thanks.
    Regards,
    bw_newbie

    You can define the number of rows of the internal table using the DESCRIBE itab command .
    As the rest have already stated a sample code snippet .
    For more info type in DESCRIBE in your prgram and click on (F1) by placing the cursor on DESCRIBE .
    You will find more options as to how you can use the DESCRIBE command according to your requirement .
    Thanks ,
    Hari

  • Grouping of rows of internal table.

    Hi all,
    I am having a requirement in which I want to group two rows of an internal table and assign a pointer to the two rows.
    This pointer variable will then be passed to ALV.
    Help reqd.
    regards.

    hi,
    AT - itab:
    push F1 to look at the documentation for grouping
    then assign the value to a field-symbol.

  • How to add a group of rows in internal table

    Hi champs,
       I have some requirement.
    I have one internal table which contain 4 columns .out of which 3 has some numeric value and first has some letters e.g A ,B,C etc.
    Now suppose i have 20 rows in itab in which 10 are A 5 are B and 5 are C .Now as column 3 has numeric values i need to get the total of column 3 for all A ,B and C .
    How to solve this problem.Please guid me.
    thanks in advance
    Jhon

    Hi,
    Check the following code:
    DATA: BEGIN OF LINE,
    COL1 TYPE C,
    COL2 TYPE I,
    COL3 TYPE I,
    END OF LINE.
    DATA ITAB LIKE HASHED TABLE OF LINE
    WITH UNIQUE KEY COL1 COL2.
    LINE-COL1 = 'A'.
    DO 3 TIMES.
    LINE-COL2 = SY-INDEX.
    LINE-COL3 = SY-INDEX ** 2.
    INSERT LINE INTO TABLE ITAB.
    ENDDO.
    LINE-COL1 = 'B'.
    DO 3 TIMES.
    LINE-COL2 = 2 * SY-INDEX.
    LINE-COL3 = ( 2 * SY-INDEX ) ** 2.
    INSERT LINE INTO TABLE ITAB.
    ENDDO.
    SORT ITAB.
    LOOP AT ITAB INTO LINE.
    WRITE: / LINE-COL1, LINE-COL2, LINE-COL3.
    AT END OF COL1.
    SUM.
    ULINE.
    WRITE: / LINE-COL1, LINE-COL2, LINE-COL3.
    SKIP.
    ENDAT.
    AT LAST.
    SUM.
    ULINE.
    WRITE: / LINE-COL1, LINE-COL2, LINE-COL3.
    ENDAT.
    ENDLOOP.
    Regards,
    Bhaskar

  • How to convert rows of internal table to columns of another internal table?

    Hi,
    Experts,
    test_data.xls:
    one two three four five
    one two three four
    one two three
    one two
    one
    CALL FUNCTION 'ALSM_EXCEL_TO_INTERNAL_TABLE'
      EXPORTING
        FILENAME                      = 'c:/test_data.xls'
        I_BEGIN_COL                   = '1'
        I_BEGIN_ROW                   = '1'
        I_END_COL                     = '10'
        I_END_ROW                     = '10'
      TABLES
        INTERN                        = it_tab
    EXCEPTIONS
       INCONSISTENT_PARAMETERS       = 1
       UPLOAD_OLE                    = 2
       OTHERS                        = 3
    output:
    0001 0001 one
    0001 0002 two
    0001 0003 three
    0001 0004 four
    0001 0005 five
    0002 0001 one
    0002 0002 two
    0002 0003 three
    0002 0004 four
    0003 0001 one
    0003 0002 two
    0003 0003 three
    0004 0001 one
    0004 0002 two
    0005 0001 one
    but i want this format:
      one two three four five
    one two three four
    one two three
    one two
    one
    i don't want this type of output display i want to display in ABAP report as in file format how can i achieve this post some ideas on it.
    Thank U,
    Shabeer ahmed.

    Hi,
    Use this piece of code :
    parameters:  p_flname type rlgrap-filename.
      data:
             li_filecontent  type standard table of alsmex_tabline ,
             lwa_filecontent type  alsmex_tabline ,
             lv_begin_col    type i value 1,
             lv_begin_row    type i value 1,
             lv_end_col      type i value 17,
             lv_end_row      type i value 65000,
             li_fieldlist    type lvc_t_fcat,
             li_data         type ref to data,
             dy_line         type ref to data.
      field-symbols:<dyntable> type standard table,
                    <fs_data> type ref to data,
                    <fs_1>,
                    <dyn_wa>,
                    <dyn_field>.
    *Transfer excel file contents to internal table
      call function 'ALSM_EXCEL_TO_INTERNAL_TABLE'
        exporting
          filename                = p_flname
          i_begin_col             = lv_begin_col
          i_begin_row             = lv_begin_row
          i_end_col               = lv_end_col
          i_end_row               = lv_end_row
        tables
          intern                  = li_filecontent
        exceptions
          inconsistent_parameters = 1
          upload_ole              = 2
          error_message           = 3
          others                  = 4.
      if sy-subrc = 0.
    *Creating the list of fields in the table
        perform f_create_tab_field tables li_fieldlist using 'BUKRS'      4 .
        perform f_create_tab_field tables li_fieldlist using 'ZPOC_KUNNR' 10 .
        perform f_create_tab_field tables li_fieldlist using 'RANL'       13.
        perform f_create_tab_field tables li_fieldlist using 'ZPEDAT'     10 .
        perform f_create_tab_field tables li_fieldlist using 'KWERT'      15 .
        perform f_create_tab_field tables li_fieldlist using 'BONUS'      2 .
        perform f_create_tab_field tables li_fieldlist using 'WAERS'      5 .
        perform f_create_tab_field tables li_fieldlist using 'ZVAL'       15 .
        perform f_create_tab_field tables li_fieldlist using 'ZQTY'       15 .
        perform f_create_tab_field tables li_fieldlist using 'KMEIN'      3 .
        assign li_data to <fs_data>.
    *CREATING INTERNAL TABLE TO store data
        call method cl_alv_table_create=>create_dynamic_table
          exporting
            it_fieldcatalog           = li_fieldlist
          importing
            ep_table                  = <fs_data>
          exceptions
            generate_subpool_dir_full = 1
            others                    = 2.
        if sy-subrc = 0.
          assign <fs_data>->* to <fs_1>.
          assign <fs_1> to <dyntable>.
    Create dynamic work area and assign to FS
          create data dy_line like line of <dyntable>.   " creating a line type of the table just created above
          assign dy_line->* to <dyn_wa>.                 " creating the work area with reference to the line type
          loop at li_filecontent into lwa_filecontent.
            assign component  lwa_filecontent-col     "accessing corresponding field in the field catalog
                of structure <dyn_wa> to <dyn_field>. "and assigning this field to a field symbol
            if sy-subrc = 0.
              <dyn_field> = lwa_filecontent-value.     " filling value for this field
            endif.
            at end of row.
              append  <dyn_wa> to <dyntable>.
              clear <dyn_wa>.
            endat.
            clear lwa_filecontent.
          endloop.
          i_input_file[] =  <dyntable>.
        endif.
      elseif sy-subrc <> 0.
        message s027 display like c_error with text-001.
        stop.
      endif.
    form f_create_tab_field  tables   p_li_fieldlist structure lvc_s_fcat
                         using    p_fname
                                  p_lenght.
      data:lwa_fieldlist   type lvc_s_fcat.
      lwa_fieldlist-fieldname = p_fname.
      lwa_fieldlist-intlen = p_lenght.
      append lwa_fieldlist to  p_li_fieldlist.
      clear lwa_fieldlist.
    endform.                    " F_CREATE_TAB_FIELD
    Regards,
    Dev.

  • How to add a row in internal table at first row

    Hi All,
                  I need to add a row in an internal table which already has some contents.I want to add this row in the first row.
    Please advice.
    Thanks in advance.

    You mean - you  want to replace the 1st record in the internal table. or you want to sum the new values to the existed record.
    If you want to replace - then you can use as
    read table itab index 1.
    if sy-subrc = 0.
        itab-f1 = 'new value'.
        modify itab index sy-tabix.
    endif.
    Regards,
    Satya

  • I need to retrieve the a set of rows in between two rows from a table.

    consider employees table and primary key employee_id.
    With out using EMPLOYEE_ID column in the where clause or between clause, I need to get the records between 104 and 116 or a set of records between two rows.
    Can any one help me in this... i know this is simple but am just a fresher to oracle development... help me grow....
    Thanks,
    Arun

    ya at last i got the out put... thank guys for thinking with me....
    SELECT rownum, employee_id FROM (SELECT rownum, employee_id FROM employees ORDER BY employee_id)
    WHERE ROWNUM <=8
    MINUS
    SELECT rownum, employee_id FROM (SELECT rownum, employee_id FROM employees ORDER BY employee_id) WHERE ROWNUM <= 4

  • 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.

  • Excel attachment contains only 1st row of Internal Table.

    Hello,
    I have designed a Vendor Ledger report and want to send the same as an excel attachment. I have made use of function module SO_NEW_DOCUMENT_ATT_SEND_API1 wherein I pass the parameters.
    The program works perfectly fine as I am receiving email along with the excel attachment. Also, the excel attachment opens without any errors. Also, the alignment of columns and data is perfect.
    But the problem is if my internal table is having 10 rows, I get only the first row of  the internal table in the excel sheet.
    I also put a break point just before calling the function module to send email, I could see that the internal table which contains the attachment is having all 10 rows.
    I really don't know what's going wrong in this.
    Request you to please help.
    Regards,
    Danish.

    Hi,
    Hi this is my code. Also, one thing I found that if i remove the Report Name i.e. "Vendor Ledger" , I get more than 1 row in my excel sheet. I feel there is some problem with the document size attributes.
    * Header for exception report
      CONCATENATE 'CC' 'Vendor' 'Stat' 'Name' 'Doc.No' 'FY' 'DDate' 'PDate'
                  'AssNo.' 'Doc.Tp' 'G/L' 'LAmt' 'LCurr' 'DAmt'
                  'D/C' 'Cl.Doc' 'TaxCd' 'TaxAmt'
                  INTO it_attachment SEPARATED BY
                  cl_abap_char_utilities=>horizontal_tab.
      CONCATENATE cl_abap_char_utilities=>cr_lf it_attachment INTO it_attachment.
      APPEND it_attachment.
    * Split Internal table data using horizontal tab.
      CLEAR it_main.
      LOOP AT it_main.
        CLEAR: lc_amt, dc_amt, tax_amt.
        lc_amt = it_main-lc_amount.
        dc_amt = it_main-amt_doccur.
        tax_amt = it_main-w_tax_base.
        CONCATENATE it_main-comp_code
                    it_main-vendor
                    it_main-status
                    it_main-name1
                    it_main-doc_no
                    it_main-fisc_year
                    it_main-doc_date
                    it_main-pstng_date
                    it_main-alloc_nmbr
                    it_main-doc_type
                    it_main-sp_gl_ind
                    lc_amt
                    it_main-loc_currcy
                    dc_amt
                    it_main-db_cr_ind
                    it_main-clr_doc_no
                    it_main-w_tax_code
                    tax_amt
                INTO it_attachment SEPARATED BY
                cl_abap_char_utilities=>horizontal_tab.
        CONCATENATE cl_abap_char_utilities=>cr_lf it_attachment INTO it_attachment.
        APPEND it_attachment.
      ENDLOOP.
    * Create Mail Body and Attachment.
      psubject = 'Vendor Ledger'.
      lv_message = 'Dear Sir/Madam,'.
      APPEND lv_message TO it_message.
      lv_message = ' '.
      APPEND lv_message TO it_message.
      lv_message = 'Attachment contain Vendor Ledger for Testing.'.
      APPEND lv_message TO it_message.
      lv_message = ' '.
      APPEND lv_message TO it_message.
      lv_message = ' '.
      APPEND lv_message TO it_message.
      lv_message = 'This is a System Generated Mail. Please do not reply.'.
      APPEND lv_message TO it_message.
    **Perform for populating mail characteristic info
      CLEAR gd_doc_data.
    * Populate the subject/generic message attributes
      gd_doc_data-obj_langu = sy-langu.
      READ TABLE it_attachment INDEX w_cnt.
      gd_doc_data-doc_size = 1.
      gd_doc_data-obj_name  = 'Danish'. "'SAPRPT'.
      gd_doc_data-obj_descr = psubject.
      gd_doc_data-sensitivty = 'F'.
    * Describe the body of the message
      CLEAR it_packing_list.
      REFRESH it_packing_list.
      it_packing_list-transf_bin = space.
      it_packing_list-head_start = 1.
      it_packing_list-head_num = 0.
      it_packing_list-body_start = 1.
      DESCRIBE TABLE it_message LINES it_packing_list-body_num.
      it_packing_list-doc_size = it_packing_list-body_num * 255.
      it_packing_list-doc_type = 'RAW'.
      APPEND it_packing_list.
    **Describe the attachment info
      CLEAR it_packing_list.
      it_packing_list-transf_bin = 'X'.
      it_packing_list-head_start = 1.
      it_packing_list-head_num = 1.
      it_packing_list-body_start = 1.
      DESCRIBE TABLE it_attachment LINES  it_packing_list-body_num.
      it_packing_list-doc_type = 'XLS'.
      it_packing_list-obj_name = 'File'.
      it_packing_list-obj_descr = 'File'.
      it_packing_list-doc_size = it_packing_list-body_num * 255.
      APPEND it_packing_list.
      REFRESH it_receivers.
      CLEAR it_receivers.
      it_receivers-receiver = 'Email Address'.
      it_receivers-rec_type = 'U'.
      it_receivers-com_type = 'INT'.
      APPEND it_receivers.
    **Function Module to send mail
      CALL FUNCTION 'SO_NEW_DOCUMENT_ATT_SEND_API1'
        EXPORTING
          document_data              = gd_doc_data
          put_in_outbox              = 'X'
          commit_work                = 'X'
        TABLES
          packing_list               = it_packing_list
          contents_bin               = it_attachment
          contents_txt               = it_message
          receivers                  = it_receivers
        EXCEPTIONS
          too_many_receivers         = 1
          document_not_sent          = 2
          document_type_not_exist    = 3
          operation_no_authorization = 4
          parameter_error            = 5
          x_error                    = 6
          enqueue_error              = 7
          OTHERS                     = 8.
    Regards,
    Danish.

  • DELETED rows from internal table

    Hi Experts,
    If I delete row/s from an internal table
    using the command DELETE ADJACENT DUPLICATES,
    is there a way to get these deleted rows.
    Thanks in advance.
    Rose

    Hi roselie,
    1. ofcourse not.
    2.hence, before that,
      u can declare another internal table,
      similar to original,
      and use like this.
    3. ITAB1[]   = ORIGINALITAB[].
    regards,
    amit m.

  • How to append  row in internal table for perticular condition

    Hi,
    I have 4 records in my internal table and i want to append row
    after second row when condition will match.
    please guide me.
    thanks in advancs
    regards
    SND

    hi,
    using key word INDEX u can insert a record in aspecified position as
    if internal table is with header line.
    INSERT <internaltable> index SY_INDEX [or index no if u  know where to insert]
    with out header line.
    INSERT <internaltable> FROM <workarea> index SY_INDEX [or index no if u  know where to insert]
    if condition is true.
    insert itab index 2.
    endif.
    if helpful reward some points.
    with regards,
    Suresh.A

  • Appending empty rows in internal table

    Hi,
      i am using table control, where there is a condition, some row may left empty. end if i press enter button the empty row is filled by the next available record. My need is to pick the records in the table control to the internal table including the empty rows as it is.

    Hi Karthikeyan,
    By default with user pressinng enter, empty rows will get deleted.
    How are you populating your table control? Is it from standard transaction or your internal table?
    If it is from your internal table, you can add anothe flag field for empty row.
    Whenever row is empty in your internal table, mark flag field as 'X', so in the table control you these entries will not get vanished with pressing of enter.
    This is one idea and you can build on this. You can make this flag column as non editable so that no one can change these.
    hope this helps,
    ags.

  • Compare two rows in same table

    Hi,
    I want to compare two rows (some columns) in the same table, and if the data in the data columns is different, I want to pick the latest one. The table is date tracked. For instance I have an address table with different addresses for an employee with effective date. I want to be able to pick the latest row if the postal code is different for the 2 rows. Is this possible in sql. I can do this in Pl/sql, but dont want to use it. Eg
    address_id, postal_code, person_id,last_update_date
    123, pn123,1,12-JAN-01
    124,pu124,1,13-JAN-01
    I want to be able to retrieve just the second line.
    Any help is appreciated

    Welcome to the forum!
    Whenever you post please provide your 4 digit Oracle version (result of SELECT * FROM V$VERSION).
    >
    The table is date tracked. For instance I have an address table with different addresses for an employee with effective date. I want to be able to pick the latest row if the postal code is different for the 2 rows.
    >
    Your question is a little confusing because you are using terms like 'date tracked' and 'effective date' without explaining exactly what your definitions of those terms is.
    Why do you want the latest record ONLY if the postal code is different? What if the address is different? Then which record do you want?
    Why not just take the record for each person/company that has the latest date? If the data is the same then it doesn't which record you get so the one with the latest date will do. And if the data is different taking the one with the latest date gives you the latest data.
    The classic definition of effective date is 'the date the information becomes effective'. Information with a given effective date is NOT in effect before that date and is SUPERCEDED when data is entered with a later effective date if the actual date is later than or equal to the effective date. Using your data
    >
    123, pn123,1,12-JAN-01
    124,pu124,1,13-JAN-01
    >
    The first record IS NOT effective for dates prior to 12-JAN-01. In fact for a query looking for data prior to that date there isn't any data.
    The first record is also NOT effective for dates on or after 13-JAN-01. Only the second record is effective.
    If you added a record for 14-JAN-01 this record would not be effective until on or after that date (i.e. not for another 4 1/2 months).
    So for the classic definition of effective date the query needs to provide the AS OF date to use to obtain the data. If, as in your system, you are not allowed to create records with dates in the future and you just want the latest record then you can just select the record with the MAX(myDate) value for the given person_id, address_id or whatever your key values are.
    Edited by: rp0428 on Aug 11, 2012 7:50 AM

  • ALV - How to set selected rows into internal table

    Hi all,
    I am tying to set with an 'X' flag the selected rows in my ALV using an internal table that contains all rows showed.
    More exactly I have tried to follow these steps.
    1) I have added the filed SEL (type SEL) to my ALV structure zrt_bo_slabsend and I defined my internal table in this way
         DATA: gt_report TYPE STANDARD TABLE OF zrt_bo_slabsend,
                    gw_report TYPE zrt_bo_slabsend.
    2) I have set gw_layo-box_fname = 'SEL' to gw_layo (ALV layout)
    Pressing the "delete button" that I have insert on the top of the ALV, I intercept correctly my user command and I call a form (named "delete_lines") where I have this abap code
    FORM delete_lines.
        DATA: l_subrc          LIKE sy-subrc,
            lw_grid_settings LIKE lvc_s_glay.
    gw_layo-box_fname         = 'SEL'.
                                     "set field name to store row selection
      gw_layo-edit              = 'X'. "makes whole ALV table editable
      gw_layo-zebra             = 'X'.
    gv_repid = sy-repid.
      call function 'REUSE_ALV_GRID_DISPLAY_LVC'
      exporting
          i_callback_program       = gv_repid
         i_callback_pf_status_set = gc_status
         i_callback_user_command  = gc_user_command
         is_layout_lvc            = gw_layo
         it_fieldcat_lvc          = gw_fkat
         i_grid_settings          = lw_grid_settings
          i_save                   = 'X'
          is_variant               = variant
          it_events                = gt_events
        TABLES
          t_outtab                 = gt_report
        EXCEPTIONS
          program_error            = 1
          OTHERS                   = 2.
      LOOP AT gt_report ASSIGNING <report> WHERE SEL = 'X'.
        DELETE gt_report.
      ENDLOOP.
    ENDFORM.
    I'd like to select many rows in my ALV report, than by pressing the delete button I'd like to see a refresh of my ALV, without the selected rows. I want to save it only at the end of my action, only by pressing the save button.
    Any suggestion about the abap code will be well appreciated.
    Thanks in advance for your kind help.
    Regards.
        Giovanni

    Hi Giovanni,
    I am using the method:-
    CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY_LVC'
    EXPORTING
    *   I_INTERFACE_CHECK                 = ' '
    *   I_BYPASSING_BUFFER                =
    *   I_BUFFER_ACTIVE                   =
       I_CALLBACK_PROGRAM                = gd_REPID
       I_CALLBACK_PF_STATUS_SET          = 'UDIT'
       I_CALLBACK_USER_COMMAND           = 'USER_COMMAND'
    *   I_CALLBACK_TOP_OF_PAGE            = ' '
    *   I_CALLBACK_HTML_TOP_OF_PAGE       = ' '
    *   I_CALLBACK_HTML_END_OF_LIST       = ' '
    *   I_STRUCTURE_NAME                  =
    *   I_BACKGROUND_ID                   = ' '
       I_GRID_TITLE                      = 'Mainatin cell entry'
    *   I_GRID_SETTINGS                   =
       IS_LAYOUT_LVC                     = GS_LAYOUT
       IT_FIELDCAT_LVC                   = I_FIELDCAT[]
    *   IT_EXCLUDING                      =
    *   IT_SPECIAL_GROUPS_LVC             =
    *   IT_SORT_LVC                       =
    *   IT_FILTER_LVC                     =
    *   IT_HYPERLINK                      =
    *   IS_SEL_HIDE                       =
       I_DEFAULT                         = 'X'
    *   I_SAVE                            = 'X'
    *   IS_VARIANT                        =
       IT_EVENTS                         =
       IT_EVENT_EXIT                     =
    *   IS_PRINT_LVC                      =
    *   IS_REPREP_ID_LVC                  =
       I_SCREEN_START_COLUMN             = 30
       I_SCREEN_START_LINE               = 14
       I_SCREEN_END_COLUMN               = 120
       I_SCREEN_END_LINE                 = 25
    *   IT_EXCEPT_QINFO_LVC               =
    *   I_HTML_HEIGHT_TOP                 =
    *   I_HTML_HEIGHT_END                 =
    * IMPORTING
    *   E_EXIT_CAUSED_BY_CALLER           =
    *   ES_EXIT_CAUSED_BY_USER            =
      TABLES
        T_OUTTAB                          = IT_ZCP_DEMAND_SYS1
    * 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.
    I have made five buttons on my toolbar (add, delete, save, back, exit).
    Kindly tell me how can I catch the sy-ucomm of these buttons.
    NOTE: this FM is written inside an user-exit, so I cannot make forms.
    Thanks in advance.

  • Append screen inserted row to internal table

    Hi Experts,
    I have created a program using table control. But after filling a row when i press enter the entire row getting blank.
    So i need to append the last inserted row from table control to internal table so that when i press enter that row remains on screen.
    Thanks & Regards
    Ashutosh Katara

    Hi,
    try this code  in PAI,
    IF sy-ucomm = 'ENTER'.
      if  tabc-col1 is NOT INITIAL and
         tabc-col2 is NOT INITIAL and
        tabc-col3 is NOT INITIAL and
         tabc-col4 is NOT INITIAL.
        w_tab-field1 =  tabc-col1.
        w_tab-field2 = tabc-col2.
        w_tab-field3 = tabc-col3.
        w_tab-field3 =  tabc-col4.
       modify <itab> FROM <workarea> INDEX sy-tabix.
    ENDIF.
    ENDIF

Maybe you are looking for

  • Upload a set of files from presentation server to app server.

    Hello, I need an urgent help. I know how to use GUI_UPLOAD fm for simple file uploading. However, my requirement is that in my report program(on selection screen) I give the source directory(presentation server) and the target directory (application

  • Problems installing adobe AIR

    I'm having problems installing Adobe AIR. The installer launches two processes but nothing happens after that. I'm using a windows 7 pc. Here is the install log I found: [2010-09-16:16:41:49] Performing runtime update [2010-09-16:16:41:49] UI SWF loa

  • How to find out what process touched a file

    I am currently running Leopard 10.5.7 on a MacBook. Some of my system files' permissions keep getting screwed up. It happens randomly, and when it does I have to repair permission and reboot the computer to fix it. I am trying to isolate the problem.

  • FrameMaker 11 and Windows 8.1 - Compatible?

    I am a relative newcomer and am not sure if this question belongs here.  If not, please let me know. I am about to upgrade to Windows 8.1 (won't go into why) and of course I need to make sure FrameMaker 11 works there.  Does it? Thanks ALOT in advanc

  • Can't pacman virtualbox-ose [SOLVED]

    Hi! I'm trying to install virtualbox-ose. I've never used it before (as well as any other virtual machine). But the problem is that I can't install it via pacman. It says: resolving dependencies... looking for inter-conflicts... error: failed to prep