Write data of a table to an excel sheet

Hi
How i can write data of a table to an excel sheet?
regard
deemy

Search this forum for 1.2 Jiga-examples...

Similar Messages

  • How to transfer data more than 255 char from excel sheet to internal table.

    Hello Experts,
    I have a requirement where i have a text field in the excel sheet of more than 255 char and need to be updated in the text element. To do that i need to transfer the excel sheet data to an internal table where one of the field is more than 255 char.
    in the standard function module it works only upto 255 char. Can you help me if we have some other way to get more than 255 char in the internal table from excel sheet.
    Thanks in Advance.
    BR,
    RaJ.

    Using .xls, it is not possible transfer data more than 255 characters from excel sheet. However if the excel sheet is saved as Comma Delimited format or Tab Delimited format, then using GUI_DOWNLOAD function module data more than 255 characters can be transferred.
    File name should be : .csv (Comma Delimited format)  or .txt (Tab Delimited format)
    File Type would still remain 'ASC' while calling function module GUI_DOWNLOAD
    Also In the internal table declare the field type as String or LCHAR.
    Eg:
    TYPES: begin of ty_file,
            col_a TYPE string,
          end of ty_file.
    DATA: i_file type standard table
                   of ty_file
                 with header line
    CALL FUNCTION 'GUI_UPLOAD'
      EXPORTING
        FILENAME                      =  'C:\test.csv'
      TABLES
        DATA_TAB                      = i_file

  • Export Data of a Web Report  having 2-3 Queries(tables) Onto 1 Excel Sheet

    I have a Report designed in Web Application Designer. It has 2 or more Table Web Items in it to which different queries are bound.
    Although the data of these queries is shown as one Report but to the user it is very annoying when he has to export the Data separately for each block and then copy-paste in order to have a single Exported File (as till then the user thinks it is just one Report).
    The question is : Is there a way in which one can Export entire Data of a Web Report  having 2 Queries(tables) Onto 1 Excel Sheet once, so that 2-3 exports or more from context Menu, and then copy-paste from excel, can be avoided?

    Hi , I have gone through this document
    got this installed (the pre requisites) through SAP admin.
    & now the  code in html pane is  as below :
    First I am trying with Button option with only one dataprovider. Later will do changes for context menu option & more dataproviders.
    But when i click on "Web printing with excel" , progress bar finishes & nothing happens.
    Should't the result set be exported to Excel
    Am i missing on some part.
    Best Regards
    Deepali

  • How to extract the data from module pool program to Excel Sheet?

    Hi Guys
            I am having a requirement to transfer the data from Module pool screen to excel sheet directly.
            This is an urgent requirement.
            So plz reply me with some coding examples.
            I will give points for that.

    This report extract excel file. From that concept you can easily extract data from module pool program also by coding in PAI of the screen.
    REPORT ztest1 .
    * this report demonstrates how to send some ABAP data to an
    * EXCEL sheet using OLE automation.
    include ole2incl.
    * handles for OLE objects
    data: h_excel type ole2_object,        " Excel object
          h_mapl type ole2_object,         " list of workbooks
          h_map type ole2_object,          " workbook
          h_zl type ole2_object,           " cell
          h_f type ole2_object,            " font
          h_c type ole2_object.            " color
    DATA: FILENAME LIKE RLGRAP-FILENAME.
    tables: spfli.
    data  h type i.
    * table of flights
    data: it_spfli like spfli occurs 10 with header line.
    *&   Event START-OF-SELECTION
    start-of-selection.
    * read flights
      select * from spfli into table it_spfli.
    * display header
      uline (61).
      write: /     sy-vline no-gap,
              (3)  'Flg'(001) color col_heading no-gap, sy-vline no-gap,
              (4)  'Nr'(002) color col_heading no-gap, sy-vline no-gap,
              (20) 'Von'(003) color col_heading no-gap, sy-vline no-gap,
              (20) 'Nach'(004) color col_heading no-gap, sy-vline no-gap,
              (8)  'Zeit'(005) color col_heading no-gap, sy-vline no-gap.
      uline /(61).
    * display flights
      loop at it_spfli.
        write: / sy-vline no-gap,
                 it_spfli-carrid color col_key no-gap, sy-vline no-gap,
                 it_spfli-connid color col_normal no-gap, sy-vline no-gap,
                 it_spfli-cityfrom color col_normal no-gap, sy-vline no-gap,
                 it_spfli-cityto color col_normal no-gap, sy-vline no-gap,
                 it_spfli-deptime color col_normal no-gap, sy-vline no-gap.
      endloop.
      uline /(61).
    * tell user what is going on
      call function 'SAPGUI_PROGRESS_INDICATOR'
         exporting
    *           PERCENTAGE = 0
               text       = text-007
           exceptions
                others     = 1.
    * start Excel
      create object h_excel 'EXCEL.APPLICATION'.
    *  PERFORM ERR_HDL.
      set property of h_excel  'Visible' = 1.
    *  CALL METHOD OF H_EXCEL 'FILESAVEAS' EXPORTING #1 = 'c:kis_excel.xls'
    *  PERFORM ERR_HDL.
    * tell user what is going on
      call function 'SAPGUI_PROGRESS_INDICATOR'
         exporting
    *           PERCENTAGE = 0
               text       = text-008
           exceptions
                others     = 1.
    * get list of workbooks, initially empty
      call method of h_excel 'Workbooks' = h_mapl.
      perform err_hdl.
    * add a new workbook
      call method of h_mapl 'Add' = h_map.
      perform err_hdl.
    * tell user what is going on
      call function 'SAPGUI_PROGRESS_INDICATOR'
         exporting
    *           PERCENTAGE = 0
               text       = text-009
           exceptions
                others     = 1.
    * output column headings to active Excel sheet
      perform fill_cell using 1 1 1 200 'Carrier id'(001).
      perform fill_cell using 1 2 1 200 'Connection id'(002).
      perform fill_cell using 1 3 1 200 'City from'(003).
      perform fill_cell using 1 4 1 200 'City to'(004).
      perform fill_cell using 1 5 1 200 'Dep. Time'(005).
      loop at it_spfli.
    * copy flights to active EXCEL sheet
        h = sy-tabix + 1.
        if it_spfli-carrid cs 'AA'.
          perform fill_cell using h 1 0 000255000 it_spfli-carrid.
        elseif it_spfli-carrid cs 'AZ'.
          perform fill_cell using h 1 0 168000000 it_spfli-carrid.
        elseif it_spfli-carrid cs 'JL'.
          perform fill_cell using h 1 0 168168000 it_spfli-carrid.
        elseif it_spfli-carrid cs 'LH'.
          perform fill_cell using h 1 0 111111111 it_spfli-carrid.
        elseif it_spfli-carrid cs 'SQ'.
          perform fill_cell using h 1 0 100100100 it_spfli-carrid.
        else.
          perform fill_cell using h 1 0 000145000 it_spfli-carrid.
        endif.
        if it_spfli-connid lt 400.
          perform fill_cell using h 2 0 255000255 it_spfli-connid.
        elseif it_spfli-connid lt 800.
          perform fill_cell using h 2 0 077099088 it_spfli-connid.
        else.
          perform fill_cell using h 2 0 246156138 it_spfli-connid.
        endif.
        if it_spfli-cityfrom cp 'S*'.
          perform fill_cell using h 3 0 155155155 it_spfli-cityfrom.
        elseif it_spfli-cityfrom cp 'N*'.
          perform fill_cell using h 3 0 189111222 it_spfli-cityfrom.
        else.
          perform fill_cell using h 3 0 111230222 it_spfli-cityfrom.
        endif.
        if it_spfli-cityto cp 'S*'.
          perform fill_cell using h 4 0 200200200 it_spfli-cityto.
        elseif it_spfli-cityto cp 'N*'.
          perform fill_cell using h 4 0 000111222 it_spfli-cityto.
        else.
          perform fill_cell using h 4 0 130230230 it_spfli-cityto.
        endif.
        if it_spfli-deptime lt '020000'.
          perform fill_cell using h 5 0 145145145 it_spfli-deptime.
        elseif it_spfli-deptime lt '120000' .
          perform fill_cell using h 5 0 015215205 it_spfli-deptime.
        elseif it_spfli-deptime lt '180000' .
          perform fill_cell using h 5 0 000215205 it_spfli-deptime.
        else.
          perform fill_cell using h 5 0 115115105 it_spfli-deptime.
        endif.
      endloop.
    * EXCEL FILENAME
      CONCATENATE SY-REPID '_' SY-DATUM+6(2) '_' SY-DATUM+4(2) '_'
                  SY-DATUM(4) '_' SY-UZEIT '.XLS' INTO FILENAME.
      CALL METHOD OF H_MAP 'SAVEAS' EXPORTING #1 = FILENAME.
      free object h_excel.
      perform err_hdl.
    *       FORM FILL_CELL                                                *
    *       sets cell at coordinates i,j to value val boldtype bold       *
    form fill_cell using i j bold col val.
      call method of h_excel 'Cells' = h_zl
        exporting
          #1 = i
          #2 = j.
      perform err_hdl.
      set property of h_zl 'Value' = val .
      perform err_hdl.
      get property of h_zl 'Font' = h_f.
      perform err_hdl.
      set property of h_f 'Bold' = bold .
      perform err_hdl.
      set property of h_f 'Color' = col.
      perform err_hdl.
    endform.                    "FILL_CELL
    *&      Form  ERR_HDL
    *       outputs OLE error if any                                       *
    *  -->  p1        text
    *  <--  p2        text
    form err_hdl.
      if sy-subrc <> 0.
        write: / 'OLE-Automation Error:'(010), sy-subrc.
        stop.
      endif.
    endform.                    " ERR_HDL

  • SAP Script - How to write data in a table format.

    Hi All,
    In my requirement, I need to show item data in a table format ( In a box, with horizental & veritcal lines.
    can somebody pl give me a small code to do this.
    Regards,
    Hardik

    Hi
    SCRIPT BOXES
    POSITION WINDOW
    SIZE WIDTH '160' MM HEIGHT '140' MM
    BOX FRAME 10 TW
    Box
    BOX HEIGHT '11' MM WIDTH '160' MM FRAME 10 TW INTENSITY 35
    linessssssss
    BOX XPOS '20' MM WIDTH 0 TW HEIGHT '140' MM FRAME 10 TW
    BOX XPOS '45' MM WIDTH 0 TW HEIGHT '140' MM FRAME 10 TW
    BOX XPOS '80' MM WIDTH 0 TW HEIGHT '140' MM FRAME 10 TW
    BOX XPOS '120' MM WIDTH 0 TW HEIGHT '140' MM FRAME 10 TW
    Boxes, Lines, Shading: BOX, POSITION, SIZE
    Use the BOX, POSITION, and SIZE commands for drawing boxes, lines, and shading to print particular windows within a form or passages of text within a window in a frame or with shading.
    The SAP printer drivers that are based on page-oriented printers (the HP LaserJet driver HPL2, the Postscript driver POST, the Kyocera Prescribe driver PRES) employ these commands when printing. Line printers and page-oriented printers not supported in the standard ignore these commands. You can view the resulting printer output in the SAPscript print preview.
    Syntax:
    /: BOX [XPOS] [YPOS] [WIDTH] [HEIGHT] [FRAME] [INTENSITY]
    /: POSITION [XORIGIN] [YORIGIN] [WINDOW] [PAGE]
    /: SIZE [WIDTH] [HEIGHT] [WINDOW] [PAGE]
    BOX Command
    Syntax
    /: BOX [XPOS] [YPOS] [WIDTH] [HEIGHT] [FRAME] [INTENSITY]
    Effect: draws a box of the specified size at the specified position.
    Parameters: For each of XPOS, YPOS, WIDTH, HEIGHT, and FRAME, you must specify both a measurement and a unit of measurement. Specify the INTENSITY parameter as a percentage between 0 and 100.
    XPOS, YPOS
    Upper left corner of the box, relative to the values of the POSITION command.
    Default: Values specified in the POSITION command.
    The following calculation is performed internally to determine the absolute output position of a box on the page:
    X(abs) = XORIGIN + XPOS
    Y(abs) = YORIGIN + YPOS
    WIDTH
    Width of the box. Default: WIDTH value of the SIZE command.
    HEIGHT
    Height of the box. Default: HEIGHT value of the SIZE command.
    FRAME
    Thickness of frame.
    Default: 0 (no frame).
    INTENSITY
    Grayscale of box contents as %.
    Default: 100 (full black)
    Measurements: You must specify decimal numbers as literal values (like ABAP numeric constants) by enclosing them in inverted commas. Use the period as the decimal point character. See also the examples listed below.
    Units of measurement: The following units of measurement may be used:
    TW (twip)
    PT (point)
    IN (inch)
    MM (millimeter)
    CM (centimeter)
    LN (line)
    CH (character).
    The following conversion factors apply:
    1 TW = 1/20 PT
    1 PT = 1/72 IN
    1 IN = 2.54 CM
    1 CM = 10 MM
    1 CH = height of a character relative to the CPI specification in the form header
    1 LN = height of a line relative to the LPI specification in the form header
    /: BOX FRAME 10 TW
    Draws a frame around the current window with a frame thickness of 10 TW (= 0.5 PT).
    /: BOX INTENSITY 10
    Fills the window background with shading having a gray scale of 10 %.
    /: BOX HEIGHT 0 TW FRAME 10 TW
    Draws a horizontal line across the complete top edge of the window.
    /: BOX WIDTH 0 TW FRAME 10 TW
    Draws a vertical line along the complete height of the left hand edge of the window.
    /: BOX WIDTH '17.5' CM HEIGHT 1 CM FRAME 10 TW INTENSITY 15
    /: BOX WIDTH '17.5' CM HEIGHT '13.5' CM FRAME 10 TW
    /: BOX XPOS '10.0' CM WIDTH 0 TW HEIGHT '13.5' CM FRAME 10 TW
    /: BOX XPOS '13.5' CM WIDTH 0 TW HEIGHT '13.5' CM FRAME 10 TW
    Draws two rectangles and two lines to construct a table of three columns with a highlighted heading section.
    POSITION Command
    Syntax
    /: POSITION [XORIGIN] [YORIGIN] [WINDOW] [PAGE]
    Effect: Sets the origin for the coordinate system used by the XPOS and YPOS parameters of the BOX command. When a window is first started, the POSITION value is set to refer to the upper left corner of the window (default setting).
    Parameters: If a parameter value does not have a leading sign, then its value is interpreted as an absolute value, in other words, as a value that specifies an offset from the upper left corner of the output page. If a parameter value is specified with a leading sign, then the new value of the parameter is calculated relative to the old value. If one of the parameter specifications is missing, then no change is made to this parameter.
    XORIGIN, YORIGIN
    Origin of the coordinate system.
    WINDOW
    Sets the values for the left and upper edges to match those of the current window (default setting).
    PAGE
    Sets the values for the left and upper edges to match those of the current output page (XORIGIN = 0 cm, YORIGIN = 0 cm).
    /: POSITION WINDOW
    Sets the origin for the coordinate system to the upper left corner of the window.
    /: POSITION XORIGIN 2 CM YORIGIN '2.5 CM'
    Sets the origin for the coordinate system to a point 2 cm from the left edge and 2.5 cm from the upper edge of the output page.
    /: POSITION XORIGIN '-1.5' CM YORIGIN -1 CM
    Shifts the origin for the coordinates 1.5 cm to the left and 1 cm up.
    SIZE Command
    Syntax
    /: SIZE [WIDTH] [HEIGHT] [WINDOW] [PAGE]
    Effect: Sets the values of the WIDTH and HEIGHT parameters used in the BOX command. When a window is first started, the SIZE value is set to the same values as the window itself (default setting).
    Parameters: If one of the parameter specifications is missing, then no change is made to the current value of this parameter. If a parameter value does not have a leading sign, then its value is interpreted as an absolute value. If a parameter value is specified with a leading sign, then the new value of the parameter is calculated relative to the old value.
    WIDTH, HEIGHT
    Dimensions of the rectangle or line.
    WINDOW
    Sets the values for the width and height to the values of the current window (default setting).
    PAGE
    Sets the values for the width and height to the values of the current output page.
    /: SIZE WINDOW
    Sets WIDTH and HEIGHT to the current window dimensions.
    /: SIZE WIDTH '3.5' CM HEIGHT '7.6' CM
    Sets WIDTH to 3.5 cm and HEIGHT to 7.6 cm.
    /: POSITION WINDOW
    /: POSITION XORIGIN -20 TW YORIGIN -20 TW
    /: SIZE WIDTH +40 TW HEIGHT +40 TW
    /: BOX FRAME 10 TW
    A frame is added to the current window. The edges of the frame extend beyond the edges of the window itself, so as to avoid obscuring the leading and trailing text characters.
    <REMOVED BY MODERATOR>
    Regards
    Anji
    Edited by: Alvaro Tejada Galindo on Jul 8, 2008 10:59 AM

  • BDC table control using Excel sheet upload

    Hi All,
    I am working BDC table control.I want to upload the From excel sheet.I am using the FM ALSM_EXCEL_TO_INTERNAL_TABLE to upload the the data into my internal table.The data is populating in the internal table.
    Now i have problem tat how to populate this excel sheet data to the Bdc table control.
    Can nybody help me out.\[removed by moderator\]
    Thanks,
    Swapna.
    Edited by: Jan Stallkamp on Jul 25, 2008 10:57 AM

    after fetching data from EXCEL sheet, each column data (in excel sheet) will be uploaded to individual record into your internal table along with row number and column number, loop through that internal table and collect all your excel data into record format.pls refer the below code.
    data:
         i_excel    type alsmex_tabline occurs 0 with header line,
         l_row      type i value 1.
    data:
         begin of x_data occurs 0,
                kunnr     like RF02L-KUNNR,
                klimk(17) type c,
                CTLPC     like knkk-CTLPC,
          end  of x_data,
          begin of x_data1 occurs 0,
                data(106),
          end   of x_data1.
    call function 'ALSM_EXCEL_TO_INTERNAL_TABLE'
       exporting
         filename                      = p_fname
         i_begin_col                   = 1
         i_begin_row                   = 1
         i_end_col                     = no.of columns in your excel file
         i_end_row                     = no.of rows in your file
       tables
         intern                        = i_excel.
    if sy-subrc = 0.
       loop at i_excel.
         if l_row <> i_excel-row.
            append x_data.
            clear x_data.
         endif.
         case i_excel-col.
            when 1.
              x_data-kunnr = i_excel-value.
            when 2.
              x_data-klimk = i_excel-value.
            when 3.
              x_data-CTLPC = i_excel-value.
         endcase.
         l_row = i_excel-row.
         clear i_excel.
         at last.
            append x_data.
         endat.
       endloop.
    endif.
    then loop through the internal table X_DATA, pass the data to your table control like.
    tbl_control-field1(1) = x_data-field1.
    tbl_control-field2(1) = x_data-field2.
    tbl_control-fieldn(1) = x_data-fieldn.
    Regards,
    Sreeram.

  • [webdynpro] How to get the data from database and store in Excel sheet

    Hi All-
    I am developing an application in Webdynpro and I need to provide a URL ( link ) which if clicked , need to collect the data from Database ( SQL Server ) and puts in an Excel Sheet corresponding fields and opens the sheet.....
    Please look into this issue and help me out......
    Regards,
    Cris

    Hi Cris,
    Add-on to wat santosh has pointed to:
    Exporting table data to MS-Excel Sheet(enhanced Web Dynpro Binary Cache)
    (Or) If you have implemented your logic to get Database records below Blog should guide you in opening an excel with ur records.
    Exporting table data to MS-Excel Sheet(enhanced Web Dynpro Binary Cache)
    Regards,
    N.

  • Reading data in a tab in an excel sheet

    Hi,
    I would like to read the data in an excel sheet and upload into an internal table for processing. I was able to do it using function module ALSM_EXCEL_TO_INTERNAL_TABLE but I am not able to read a particular tab. My excel sheet has tabls like A, B, C and D and I want to read only tab C. But currently, it reads data in  tab A.
    regards,
    Srini.

    Pls check this and review it once. it works for 2 excel sheets in single excel file to read. Pls reward me if its helpful.  Thanks !
       FUNCTION z_uploading_from_2sheets.
    *"*"Local Interface:
    *"  IMPORTING
    *"     REFERENCE(FILE_NAME) TYPE  RLGRAP-FILENAME
    *"     REFERENCE(START_ROW_SHEET1) TYPE  I
    *"     REFERENCE(START_COLUMN_SHEET1) TYPE  I
    *"     REFERENCE(START_ROW_SHEET2) TYPE  I
    *"     REFERENCE(START_COLUMN_SHEET2) TYPE  I
    *"     REFERENCE(END_ROW_SHEET1) TYPE  I
    *"     REFERENCE(END_COLUMN_SHEET1) TYPE  I
    *"     REFERENCE(END_ROW_SHEET2) TYPE  I
    *"     REFERENCE(END_COLUMN_SHEET2) TYPE  I
    *"  TABLES
    *"      IT_DATA1 STRUCTURE  ALSMEX_TABLINE
    *"      ALSMEX_TABLINE STRUCTURE  ALSMEX_TABLINE
    *"  EXCEPTIONS
    *"      INCONSISTENT_PARAMETERS
    *"      UPLOAD_OLE
      TYPES: ty_t_sender(1500) TYPE c.
      DATA: excel_tab TYPE TABLE OF ty_s_senderline,
      excel_tab1 TYPE TABLE OF ty_s_senderline.
      DATA: ld_separator TYPE c.
      DATA: application TYPE ole2_object,
      workbook TYPE ole2_object,
      sheet TYPE ole2_object,
      range TYPE ole2_object,
      worksheet TYPE ole2_object.
      DATA: h_cell TYPE ole2_object,
      h_cell1 TYPE ole2_object.
      DATA: ld_rc TYPE i.
      DATA: it_data TYPE STANDARD TABLE OF  alsmex_tabline.
    *MESSAGE DEFINATION
      DEFINE m_message.
    *Function Module To Upload Data From
    *Excel File Into Two Internal Tables
    *© 2005 SAP AG 6
        case sy-subrc.
          when 0.
          when 1.
            message id sy-msgid type sy-msgty number sy-msgno
            with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
          when others. raise upload_ole.
        endcase.
      END-OF-DEFINITION.
    *PARAMETER CHECK.
      IF start_row_sheet1 > end_row_sheet1.
        RAISE inconsistent_parameters.
      ENDIF.
      IF start_column_sheet1 > end_column_sheet1.
        RAISE inconsistent_parameters.
      ENDIF.
      IF start_row_sheet2 > end_row_sheet2.
        RAISE inconsistent_parameters.
    *Function Module To Upload Data From Excel File Into Two Internal Tables
      ENDIF.
      IF start_column_sheet2 > end_column_sheet2.
        RAISE inconsistent_parameters.
      ENDIF.
      CLASS cl_abap_char_utilities DEFINITION LOAD.
      ld_separator = cl_abap_char_utilities=>horizontal_tab.
    *OPENING EXCEL FILE
      IF application-header = space OR application-handle = -1.
        CREATE OBJECT application 'Excel.Application'.
        m_message.
      ENDIF.
      CALL METHOD OF
          application
          'Workbooks' = workbook.
      m_message.
      CALL METHOD OF
          application
          'Workbooks' = workbook.
      m_message.
      CALL METHOD OF
          workbook
          'Open'
        EXPORTING
          #1       = file_name.
      m_message.
      CALL METHOD OF
          application
          'Worksheets' = sheet
        EXPORTING
          #1           = 1.
    *Function Module To Upload Data From Excel File Into Two Internal Tables
      m_message.
      CALL METHOD OF
          application
          'Worksheets' = sheet
        EXPORTING
          #1           = 1.
      m_message.
      CALL METHOD OF
          sheet
          'Activate'.
      m_message.
      GET PROPERTY OF application 'ACTIVESHEET' = sheet.
      m_message.
    *MARKING OF WHOLE SPREADSHEET
      CALL METHOD OF
          sheet
          'Cells' = h_cell
        EXPORTING
          #1      = start_row_sheet1
          #2      = start_column_sheet1.
      m_message.
      CALL METHOD OF
          sheet
          'Cells' = h_cell1
        EXPORTING
          #1      = end_row_sheet1
          #2      = end_column_sheet1.
      m_message.
      CALL METHOD OF
          sheet
          'RANGE' = range
        EXPORTING
          #1      = h_cell
          #2      = h_cell1.
      m_message.
      CALL METHOD OF
          range
          'SELECT'.
      m_message.
    *Function Module To Upload Data From Excel File Into Two Internal Tables
    *Copy marked area (SHEET1) into Clippboard
      CALL METHOD OF
          range
          'COPY'.
      m_message.
    *Read clipboard into ABAP
      CALL METHOD cl_gui_frontend_services=>clipboard_import
        IMPORTING
          data                 = excel_tab
        EXCEPTIONS
          cntl_error           = 1
          error_no_gui         = 2
          not_supported_by_gui = 3
          OTHERS               = 4.
      IF sy-subrc <> 0.
        MESSAGE a037(alsmex).
      ENDIF.
      PERFORM separated_to_intern_convert TABLES excel_tab it_data
      USING ld_separator.
      APPEND LINES OF it_data TO it_data1.
    *Function Module To Upload Data From Excel File Into Two Internal Tables
    *Clear the clipboard
      REFRESH excel_tab.
      CALL METHOD cl_gui_frontend_services=>clipboard_export
        IMPORTING
          data                 = excel_tab
        CHANGING
          rc                   = ld_rc
        EXCEPTIONS
          cntl_error           = 1
          error_no_gui         = 2
          not_supported_by_gui = 3
          OTHERS               = 4.
    *Working in Second Excel Work Sheet
      CALL METHOD OF
          application
          'Worksheets' = sheet
        EXPORTING
          #1           = 2.
      m_message.
      CALL METHOD OF
          sheet
          'Activate'.
      m_message.
    *Function Module To Upload Data From Excel File Into Two Internal Tables
      GET PROPERTY OF application 'ACTIVESHEET' = sheet.
      m_message.
    *Mark Sheet2
      CALL METHOD OF
          sheet
          'Cells' = h_cell
        EXPORTING
          #1      = start_row_sheet2
          #2      = start_column_sheet2.
      m_message.
      CALL METHOD OF
          sheet
          'Cells' = h_cell1
        EXPORTING
          #1      = end_row_sheet2
          #2      = end_column_sheet2.
      m_message.
      CALL METHOD OF
          sheet
          'RANGE' = range
        EXPORTING
          #1      = h_cell
          #2      = h_cell1.
      m_message.
      CALL METHOD OF
          range
          'SELECT'.
      m_message.
    *Copy Marked Area (Sheet2) into Clippboard
      CALL METHOD OF
          range
          'COPY'.
      m_message.
    *Function Module To Upload Data From Excel File Into Two Internal Tables
    *Read Clipboard into ABAP
      CALL METHOD cl_gui_frontend_services=>clipboard_import
        IMPORTING
          data                 = excel_tab1
        EXCEPTIONS
          cntl_error           = 1
          error_no_gui         = 2
          not_supported_by_gui = 3
          OTHERS               = 4.
      IF sy-subrc <> 0.
        MESSAGE a037(alsmex).
      ENDIF.
    *PERFORM separated_to_intern_convert TABLES excel_tab1 IT_DATA2
      PERFORM separated_to_intern_convert TABLES excel_tab1 it_data
      USING ld_separator.
    *Clear Clipboard.
      REFRESH: excel_tab1.
      APPEND LINES OF it_data TO it_data1.
      CALL METHOD cl_gui_frontend_services=>clipboard_export
    *Function Module To Upload Data From Excel File Into Two Internal Tables
      IMPORTING
      data = excel_tab1
      CHANGING
      rc = ld_rc
      EXCEPTIONS
      cntl_error = 1
      error_no_gui = 2
      not_supported_by_gui = 3
      OTHERS = 4
    *Leaving Application
      CALL METHOD OF
          application
          'QUIT'.
      m_message.
    * >>>>> Begin of change note 575877
    * to kill the Excel process it's necessary to free all used objects
      FREE OBJECT h_cell.       m_message.
      FREE OBJECT h_cell1.      m_message.
      FREE OBJECT range.        m_message.
      FREE OBJECT worksheet.    m_message.
      FREE OBJECT workbook.     m_message.
      FREE OBJECT application.  m_message.
    * <<<<< End of change note 575877
    ENDFUNCTION.

  • I try to find such as pivot table like in excel sheet

    How to collect data like pivot table in excel sheet. Please help me

    Hi Chepot,
    Welcome to Apple Discussions and the Numbers '09 forum.
    Numbers does not support pivot tables, but there may be a way to accomplish what you want.
    Here's a link to search results for 'pivot AND table' in the Numbers '09 forum during the past year. Check these prior discussions. If they don't answer your question, post a reply here with further details on the arrangement of data you want to collect.
    Regards,
    Barry

  • Sap FICO tables download to excell sheet

    hi,
    I want to download the fico master tables to excell sheet.
    somebody told me to SE16N and system-list-save-local file-(spread sheet)
    while doing the same procedure i am struggling in localfile when i am clicking in same after that local file that time local file is showing properly, local file is there that is not allowing to pointout, therefore please explain me how to do and get the FICO master tables to excell sheet.
    waiting your reply soon.
    by
    sujatha

    Hi,
    Transaction code SE16N enables to enter a specific table and get the contents or records in the table. Which table name you have entered for getting the Master Data tables?
    Some of the Master data tables in FICO are as under:
    SKA1               GL Accounts CoA data
    SKB1                                        GL Accounts CC Data
    BNKA                   Bank master record
    KNA1               Customer master
    KNB1               Customer / company
    KNVV               Customer sales data
    KNBK               Bank details
    KNVH               Customer hierarchy
    KNVP               Customer partners
    KNVS               Shipment data for customer
    KNVK               Contact persons
    KNVI               Customer master tax indicator
    LFA1               Vendor master
    LFB1               Vendor per company code
    LFB5               Vendor dunning data
    LFM1               Purchasing organization data
    LFM2               Purchasing data
    LFBK               Bank details
    KNMT               Customer material info record
    BNKA               Master bank data
    CSKS               Cost Center Master Data
    CSKT               Cost center texts
    CRCO               Assignment of Work Center to Cost Center
    Thanks
    Murali.

  • How to dowload data in particular cell of designed excel sheet

    hi everyone
    i want to dowload the data in a excel sheet, but this excel sheet is designed in such a format that i have download each field of internal table in a specified cell only , <b>gui_download</b> function module simply download the data in excel sheet by taking the first cell for first field but i dont want that

    Hi Neetu,
    you can use OLE in that case.
    REPORT  ZTEST_EXCEL             .
    INCLUDE ole2incl.
    DATA: application TYPE ole2_object,
           workbook TYPE ole2_object,
           sheet TYPE ole2_object,
           cells TYPE ole2_object.
    CONSTANTS: row_max TYPE i VALUE 256.
    DATA index TYPE i.
    DATA: BEGIN OF itab1 OCCURS 0,
    first_name(10),
    last_name(10),
    END OF itab1.
    START-OF-SELECTION.
    itab1-first_name = '123445'.
    itab1-last_name = 'tesst'.
    append itab1.
    clear itab1.
    itab1-first_name = '123446'.
    itab1-last_name = 'tesst'.
    append itab1.
    clear itab1.
      CREATE OBJECT application 'excel.application'.
      SET PROPERTY OF application 'visible' = 1.
      CALL METHOD OF application 'Workbooks' = workbook.
      CALL METHOD OF workbook 'Add'.
    * Create first Excel Sheet
      CALL METHOD OF application 'Worksheets' = sheet
                                   EXPORTING #1 = 1.
      CALL METHOD OF sheet 'Activate'.
      SET PROPERTY OF sheet 'Name' = 'Sheet1'.
      LOOP AT itab1.
        index = row_max * ( sy-tabix - 1 ) + 1. " 1 - column name
        CALL METHOD OF sheet 'Cells' = cells EXPORTING #1 = index.
        SET PROPERTY OF cells 'Value' = itab1-first_name.
            index = index + 1. " 1 - column name
        CALL METHOD OF sheet 'Cells' = cells EXPORTING #1 = index.
        SET PROPERTY OF cells 'Value' = itab1-last_name.
      ENDLOOP.
    * Save excel speadsheet to particular filename
      CALL METHOD OF sheet 'SaveAs'
                     EXPORTING #1 = 'c:tempexceldoc1.xls'     "filename
                                #2 = 1.                          "fileFormat
    Regards
    vijay

  • Exporting items from a table to an excel sheet.

    I need to create a view in which there is this table which has some data which I have hard coded. Now I need to export all those data to an excel sheet on the click of this export button.
    Kindly help me on that.
    I am using NW7.2

    Dear Abinas,
    Please read this tutorial.
    http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/edc2f3c2-0401-0010-8898-acd5b6a94353?QuickLink=index&…
    Thanks & Regards,
    Patralekha

  • Data trasfer from maint. view to excel sheet

    I have one maint. view , How to trasfer the data from that maint view to excel through bdc?
    Thanks,
    Regards,
    Vishal Bhagwat.

    Hi Vishal,
    In BDC call the below FM
    You can try using KCD_EXCEL_OLE_TO_INT_CONVERT FM.
    Add values to internal table
    SORT t_cells BY row col.
    LOOP AT t_cells INTO wa_cells.
    MOVE : wa_cells-col TO l_index.
    ASSIGN COMPONENT l_index OF STRUCTURE itab TO <f_value>.
    MOVE : wa_cells-value TO <f_value>.
    AT END OF row.
    APPEND itab
    CLEAR itab.
    ENDAT.
    ENDLOOP.
    Regards,
    Aarti.

  • Oracle Forms table EXPORT into excel sheet

    Hi all,
    I have the following situation:
    I managed to export a table into an excel worksheet using OLE2 standard package, but sometimes I have to many records in the table and I was wondering if it's possible to show in Excel (while is loading the data into it) a Progress Bar or a message like "Still working...".
    Thank you in advance for your input.
    Best regards,
    Marius

    Hi guys,
    Watch this link:
    Re: Download from Oracle 10g Forms to Excell
    Regards,
    Marius

  • Reg: Download alv grid data with top of page into excel sheet

    Hi All,
    I have a selection screen with radio button for download .
    If that radio button was selected then the data will download into excel sheet (like if we execute normal ALV grid display from there we can download top-of-page and body as it is).
    AOO : 2009P               
    Fiscal year : 2009               
    Posting period : 00               
    Local Currency : USD               
    CO Area Currency :               
    Accounting standard:               
    Sector : 23               
    BB code     Period Value LC     Periodic Quantity
    AHDKGKAJ   200                         0

    Did not get your question

Maybe you are looking for

  • CS4 / Win: How can I observe a table (insert and delete)

    Hi How can i observe the insertion oder deletion of a table in my Indesign document? I have implemented a doc change observer. But I don't know if it is possible to observe the tables in this observer or how I can do that. Any help? Thanks. Hans

  • Cant get it to replace or print to new line, please help

    2 problems. The instructions are to first replace each 's' with '$' and then print each word to a new line. Here is an example: Give me a phrase: Viva Las Vegas, babies! Viva La$ Vega$, babie$. Here is my code that is not working: import java.util.*;

  • Importing svg

    Is there any fix for opening svg files in Illustrator CS6? I'm updated, not CC, but get an error for some SVG files as other users appear to get too.

  • Problems installing or running Adobe Flash Player for safari

    problems installing or running Adobe® Flash® Player for safari when trying to install Adobe Flash Player.pkg it asks to quit Dash Board client then brings up Exclamation mark up and quits install ??????

  • Alternate to Apple Brand Power Supply?

    So I've run through two power supplies (both broken where it connects with the computer) and I'd really rather not buy another apple brand supply. I understand the strange outside ring is only for the color on the charger so it's probably and any ada