Down load to excel sheet

friends,
I have a requirement to down load a list which is displayed hierarchially into an excel sheet.
1000
         18271218         qiuwiquw
          289283           djksdjskd
1001
         23232             ssdsdsd

check parameters.
and pass it according to your req,
like file name & type 
separated by...!!
and atlast pass the formated internal table
and generate file.
reward if helpful
  call function 'GUI_DOWNLOAD'
    exporting
    BIN_FILESIZE                    =
      filename                        = txtfile
     filetype                        = 'ASC'
    APPEND                          = ' '
     write_field_separator           = 'X'
     confirm_overwrite               = 'X'
    tables
      data_tab                        = it2_oh

Similar Messages

  • Se16 down load into excel sheet problem with PO number

    Dear All,
    While I download vbak table data using se16 from table VBAK ( using System > List> save --> local File --> Spreadsheet ), I get the PO number converted as error like at it's end, the last digit is becoming zero when po number is of 16 digits.  means only the last digit is converted to 0.
      For example : se16 -> vbak table -> the po numbers
    1238643210249039, when I down load in the excel sheet it is appearing as 1238643210249030
    (I means the last digit of the PO number is downloaded with error, it is always a u201C0u201D.
    if the PO number is of less than 16 digits... the above problem is not there )
    How to correct the error ? How to tell solution to functional consultant ? Can you please suggest me
    Do we need to apply any OSS message ?
    Thanks in ADVANCE.
    Edited by: sam kumar on Dec 8, 2008 5:40 PM

    Hi,
    Just found that 'Numbers in Microsoft Excel can never have more than 15 significant digits'.
    check this link from Microsoft: [http://support.microsoft.com/kb/158071|http://support.microsoft.com/kb/158071]
    check this  [http://office.microsoft.com/en-us/excel/HA102748231033.aspx|http://office.microsoft.com/en-us/excel/HA102748231033.aspx]
    [http://office.microsoft.com/en-us/excel/HA102748231033.aspx#5|http://office.microsoft.com/en-us/excel/HA102748231033.aspx#5]
    What i can suggest is, put a apostrophe (') for the value of first cell content at the beginning.
    Use Format painter to apply the same for all values in that column.
    Regards
    Raj
    Edited by: Rajasekhar Dinavahi on Dec 8, 2008 10:59 PM
    Edited by: Rajasekhar Dinavahi on Dec 8, 2008 11:00 PM
    Edited by: Rajasekhar Dinavahi on Dec 8, 2008 11:05 PM

  • Problem in down loading to excel sheet from ALV report

    Hi Experts,
    I have used the funtion module REUSE_ALV_GRID_DISPLAY, and for field catalog I have individually written the field catalog  as there are not many fields instead of using the funtion module REUSE_ALV_FIELDCATALOG_MERGE.
    Report is getting displayed well but while getting  down load to xls only numeric fields are appearing and character fields are not appearing.
    Have  I selected the function module formats correctly.
    CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
        EXPORTING
            I_BYPASSING_BUFFER          =
            I_BUFFER_ACTIVE             =
            I_INTERFACE_CHECK           = ' '
             I_CALLBACK_PROGRAM          = 'ZHR_DETAILS'
            I_CALLBACK_PF_STATUS_SET    = ' '
            I_CALLBACK_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                = 'Active ETA Details'
            I_GRID_SETTINGS             =
            IS_LAYOUT                   =
             IT_FIELDCAT                 =  RT_FCAT
            IT_EXCLUDING                =
            IT_SPECIAL_GROUPS           =
            IT_SORT                     =
            IT_FILTER                   =
            IS_SEL_HIDE                 =
            I_DEFAULT                   = 'X'
            I_SAVE                      = ' '
            IS_VARIANT                  =
            IT_EVENTS                   =
            IT_EVENT_EXIT               =
            IS_PRINT                    =
            IS_REPREP_ID                =
            I_SCREEN_START_COLUMN       = 0
            I_SCREEN_START_LINE         = 0
            I_SCREEN_END_COLUMN         = 0
            I_SCREEN_END_LINE           = 0
            I_HTML_HEIGHT_TOP           =
            I_HTML_HEIGHT_END           =
       IMPORTING
            E_EXIT_CAUSED_BY_CALLER     =
            ES_EXIT_CAUSED_BY_USER      =
         TABLES
              T_OUTTAB                    = ITAB
       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.
    Please advice me.
    Thanks in advance.
    Regards,
    Irfan Hussain

    Hi Irfan,
      This looks strange !!1
      Try to use the layout option also and checkout if it works

  • Truncation of leading Zeros when Down Loading into Excel - OLE Objects

    Hi,
    Can any one help me on this.
    I am using <b>OLE Objects</b> to download Data into Excel Sheet. Data with leading Zeros is getting truncated in Excel.
    Ex: Report Output is showing Plant Number as 0002. But when i am downloading to Excel Plant value will become 2 .
       I would like to have it as 0002 in Excel.
    I have declared Werks as CHAR of 4.I am using OLE Obects for Downloading into Excel Sheet.
    I am using "OLE2_OBJECT" I can not use any other FMs to down load to Excel.As i am modifying this program not creating.
    Thanks In Advance.
    K.Nirmala
    Message was edited by: Nirmala Reddy

    Hi Nirmala,
    While downloading to excel sheet, u need to change the number format of cell from General to Text, then leading zero's won't get deleted. For that u need to set the property of the cell. Please check this sample code,
    INCLUDE OLE2INCL.
    tables : zobrent.
    data : it_kna1 type table of zobrent with header line.
    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
    DATA  H TYPE I.
    DATA: cell1 TYPE ole2_object.
    *&   Event START-OF-SELECTION
    START-OF-SELECTION.
      select * from zobrent into table it_kna1
               where zopanid = '10001'
                and zo_brent = '050'.
    start Excel
      CREATE OBJECT H_EXCEL 'EXCEL.APPLICATION'.
      PERFORM ERR_HDL.
      SET PROPERTY OF H_EXCEL  'Visible' = 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.
    output column headings to active Excel sheet
      PERFORM FILL_CELL USING 1 1 1 'EDate'.
      PERFORM FILL_CELL USING 1 2 1 'Brent'.
      PERFORM FILL_CELL USING 1 3 1 'Zopanid'.
      PERFORM FILL_CELL USING 1 4 1 'Contract Type'.
      PERFORM FILL_CELL USING 1 5 1 'Price Type'.
      PERFORM FILL_CELL USING 1 6 1 'Installation Type'.
      PERFORM FILL_CELL USING 1 7 1 'Volume'.
      PERFORM FILL_CELL USING 1 8 1 'AQ'.
      PERFORM FILL_CELL USING 1 9 1 '00000123'.
      LOOP AT IT_KNA1.
    copy values to active EXCEL sheet
        H = SY-TABIX + 1.
        PERFORM FILL_CELL USING H 1 0 IT_KNA1-zo_effdat.
        PERFORM FILL_CELL USING H 2 0 IT_KNA1-zo_brent.
        PERFORM FILL_CELL USING H 3 0 IT_KNA1-zopanid.
      ENDLOOP.
      CALL METHOD OF h_excel 'Cells' = cell1
        EXPORTING
          #1 = 1
          #2 = 1.
      FREE OBJECT H_EXCEL.
      PERFORM ERR_HDL.
      if sy-subrc eq 0.
       write : / 'year'(001).
      endif.
         FORM FILL_CELL
    sets cell at coordinates i,j to value val boldtype bold
    FORM FILL_CELL USING I J BOLD VAL.
      CALL METHOD OF H_EXCEL 'Cells' = H_ZL EXPORTING #1 = I #2 = J.
      PERFORM ERR_HDL.
      GET PROPERTY OF H_ZL 'Font' = H_F.
      PERFORM ERR_HDL.
      SET PROPERTY OF H_F 'Bold' = BOLD .
      PERFORM ERR_HDL.
    ***Changing the format of the cell from General to Text
      <b>SET PROPERTY OF H_ZL 'NumberFormat' = '@'.</b>
      PERFORM ERR_HDL.
      SET PROPERTY OF H_ZL 'Value' = VAL .
      PERFORM ERR_HDL.
    ENDFORM.
    *&      Form  ERR_HDL
    FORM ERR_HDL.
    IF SY-SUBRC <> 0.
      WRITE: / 'Fehler bei OLE-Automation:'(010), SY-SUBRC.
      STOP.
    ENDIF.
    ENDFORM.                    " ERR_HDL
    U just paste this code in a sample program & see.
    Please reward, if found helpful.

  • Loading Multiple excel sheets in to different tables in a DB

    Hi All,
    I have problem in loading multiple excel sheets data in to according to that excelsheets tables in a DB.
    All the excel sheets are in a folder,from that folder i have to  acces all excel sheets.
    For this i am unsing script task and one dataflow task.
    But the error is coming in script task i am not able to put the path in the script..
    Is this the correct way to do like this? Or any other way?
    Can u please tell me the solution for this..Thanks in advance who are responding to this mail...
    Maruthi..

    Hi Vipin,
    Here you go with this requirement
    How to Load Multiple Sheets From Multiple Excel Files to Different Tables in SSIS Package?
    ttps://www.youtube.com/watch?v=1WXKpkwjhX8&feature=youtu.be
    I have other videos as well where you want to load all the sheets from file/s to same table 
    https://www.youtube.com/watch?v=F3sYO-S9icc&feature=youtu.be
    Check out the last links on below links all related to Excel
    http://sqlage.blogspot.com/search/label/SSIS%20Videos
    How to Create Excel file with Date-time on Each Package Execution in SSIS Package?
    How to Load Multiple Sheets to a SQL Server Table in SSIS Package?
    How to Load Data Excel File to SQL Server Table and Solve Data Conversion Issues?
    How to Load Multiple Sheets From Multiple Excel Files to Different Tables in SSIS Package?
    How to Load Data to Pre-Formatted Excel Sheet (Excel Report) in SSIS Package?
    All the best!
    http://sqlage.blogspot.com/

  • ALV Report out put not down loading in XLS sheet

    Hi Guis,
    I am trying to down load ALV report output in XLS sheet . I am selecting  LIST ->SPREADSHEET->TABLE
    I am getting the fallowing message . Even though I have 18 columns .
    An XXL list object is exported with
    8 lines and 1 columns.
    But no data has been exported in the XLS sheet.
    Will you please any body solve my problem.
    Thanks,
    Santhosh .V

    Doesn't It work if you try to export to all extensions?
    Case yes, the problem really would be with the composition of the field catalog. You can search for another one where the exportation works and compare to know.
    Try to open your ALV using the office integration to test (button that opens your output inside excel).
    Regards,
    Alysson Dias

  • Down load to XL sheet

    Hi All,
    How to down load data to XL sheet,
    And also if i provided the particular column no's of XL sheet in that column's only the data is going to be down loaded is it possible? if yes than provide the sample code.
    thanks
    krishna

    you can use function 'GUI_DOWNLOAD' to download data into the Excel file.
    check parameters.
    and pass it according to your req,
    like file name & type
    separated by...!!
    and atlast pass the formated internal table
    and generate file.
    call function 'GUI_DOWNLOAD'
    Exporting
    BIN_FILESIZE =
    filename = txtfile
    filetype = 'ASC'
    APPEND = ' '
    write_field_separator = 'X'
    confirm_overwrite = 'X'
    tables
    data_tab = it2_oh.
    Reward points if useful.

  • ALV report down load to EXCEL

    When I am trying to down load the ALV report to EXCEL. The report fields are not coming in the same order as they are in the report.
    Please advice.
    <b><REMOVED BY MODERATOR></b>
    Thank you.
    Gouri.
    Message was edited by:
            Alvaro Tejada Galindo

    Hi,
    You can use the FM - ALV_XXL_CALL.
    It is the same function module invoked when you click on the export to excel button of the ALV.
    You can pass teh field catalog of the ALV here along with the name of ur internal table and the internal table itself. It will download everything to Excel alongwith the Column headers ( depending on ur field catalog definition). Just make sure ur field catalog has the COL_Heading correctly populated.
    <b>
    Sample Code -</b> CALL FUNCTION 'ALV_XXL_CALL'
    EXPORTING
    i_tabname = 'T_GRID' " Name of the Internal table
    it_fieldcat = t_fcatk[] " Field catalog
    TABLES
    it_outtab = t_grid " Interbnal table with data
    EXCEPTIONS
    fatal_error = 1
    no_display_possible = 2
    OTHERS = 3.
    IF sy-subrc <> 0.
    MESSAGE e806(bk).
    ENDIF.
    Regards
    Sudheer

  • ALV Logo is not down loading to excel.

    Hi All,
    when we are downloading the ALV output to excel  logo is not appearing..
    please tell me how to down load logo to excel file,
    Thanks in advance..

    Hi Satya,
    Can you kindly share how?
    I am also facing the same requirement.
    Thanks!

  • How to load an Excel sheet into Oracle via SQL* Loader

    Hallo!I am trying to load an Excel spreadsheet into an Oracle 10g database via SQL*Loader.
    How do I achieve this via Oracle Enterprise Manager?
    Please give a detailed explanation especially covering the locations of the control file,infile,bad file etc for Oracle 10g running in both Windows and Linux platforms.
    Thanks.

    This has nothing to do with Oracle Enterprise Manager
    SQL Loader is command line and it needs to be installed with SQL PLUS (The wrong install type will not have it)
    Consider reviewing this:
    http://www.orafaq.com/wiki/SQL*Loader_FAQ

  • Preserving prefixed zeros  in down load to excel file

    In My application lot of character field have character zero as the starting characters. Like Company code= 0600, Property= 00390898 .
      When I do a download from Internal table to excel sheet, this character fields are showing with the zeros in front like 600 & 390898. Is there any way preserve the zeros in the excel sheet ?
      Also I would Like to know How can I move the character ( '  ) . If I used ''' then it gives compile error.
        If I can prefix this character ( ' ) , the field's will be shown with the zeros.
    Thanks for your help.
    Manoranjan

    Hi Manoranjan,
    What is the data type you are using for the Company Code in your internal table?
    You can try this way.Suppose your main internal table is itab1 where in the company code is refering the database table (T001-BUKRS).
    Declare one more internal table itab2 with company code as Character data type.
    Before downloading to excel move itab1 to itab2 and then try to use that itab2 for downloading. Now your excel sheet will have the numbers with zeros preceeding.
    Another option is after downloading to excel, I think you can change the properties of the column through Format Cells->Number tab->Text.
    Thanks,
    Srinivas

  • How to load a excel sheet on the client machine from jsp

    hai all,
    I want an excel sheet to be opened like "c:\excelsheet.xls" on the client machine from my JSP so that i can send the out put of my jsp to it.i will press a button on jsp and i want the query out put in the excel sheet. if it is already opened then it has to be closed and reopened with new data, the old data has to be lost.
    can any one help me out....
    Thanks for any help...
    regards,
    ravikiran

    Hai friend,
    you add mime type in web.xml
    for example,
    <mime-mapping>
    <extension>xls</extension>
    <mime-type>application/excel</mime-type>
    </mime-mapping>

  • SSIS Package to load multiple excel sheets using foreach loop container

    I am creating a SSIS package which is accessing an excel file and then using a Foreach loop container to load each tab to sql server. However when I try to configure the Excel source, I get the following message
    "The argument system_comobject cannot be converted into parameter type. Additional Information - Object must implement iconvertible (mscorlib)"
    Any help to resolve would be much appreciated.
    thanks
    Scott

    If the title is only using column D and the rest of the columns are empty on sheet1/row1
    AND
    if only sheet1 as headers,
    THEN you can try something like the following
    do NOT select row 1 as header or anything.
    In your foreachloop > dataflow, you will start with EXCEL connection then Conditional Split inside which you will define one case for which expression should be like If column D has value like "Title expression" && Column A == "Column A Header
    name" THEN yay or nay. You might want to look into
    FINDSTRING function to assist with this (if you choose to use FINDSTRING, you are looking for !isNull for this case..If it finds the string you are looking for, it will pass an int value (title + header) if it doesn't find the string, it will pass
    NULL (data)) or you can say If Column A, B, C,E,F,G...is NULL and D is NOT NULL && Column A = Column A Header string, then Case 1 else default.
    The default output would be the real data.
    So when sheet 1 is processing, you will have Case 1 output with 2 rows (title + header) and Default output with the rest of the rows (real data).
    For other sheets, you will have Case 1 output with 0 rows (no title + header) and Default output with the data rows.
    The above sln assumes that the data in each sheet is similar in datatypes and length perspective, you have defined input/output datatypes properly, and etc.

  • Down load to excel issue in obiee 11g

    Hi all,
    after i download to excel and open the file it is prompting as below.is there any way to get rid off the prompting,any modifications required to achieve this.
    The file you are trying to open,'Balance_sheet_Hier[1].xls',is in a different format than specified by extension.Verify that the file is not corrupted and is from a  trusted source befor opening the file.do you want to open  the file now?
    Also we want  to open the  excel in xlsx format only.
    Any help in this regard will be highly appreciated.
    Thanks,
    Chandra

    Are you using 2007 excel version?
    This warning typically occurs when exporting the contents of a table to Microsoft Excel 2007.  This alert is caused by the new extension checking mechanism introduced in Microsoft Excel 2007.
    Check this
    When you open a file in Excel 2007, you receive a warning that the file format differs from the format that the file na…
    Mark if helps.
    Thanks,

  • Down load into excel file

    Hi gurus,
                 I wanna generate a report that should download the data from the internal table to the presentation server in word formart, but the length of the word file should not be greater than 156 characters as the downloaded data is sent to RBI.
    Thanks and Regards,
    Alson.

    Hi Alson,
    you can wrap the text to a length of 156 chars using the function module:-
                CALL FUNCTION 'RKD_WORD_WRAP'
    for eg if u have any variable v_text which is 1000 chars long then u can give the outputlen = 100. This way u can split 1000 chars into 1000/100 = 10 rows. you can either store these lines in an internal table or it is also possible to store these as separate variables each of length 100 chars .
    you can refer to the following code:-
                CALL FUNCTION 'RKD_WORD_WRAP'
                      EXPORTING
                          textline                  =  v_text
                        DELIMITER                 = ' '
                          outputlen                 = 156
                      TABLES
                          out_lines                 =  i_long_text
                      EXCEPTIONS
                          outputlen_too_large       = 1
                          OTHERS                    = 2.
    Plz reward points if useful.
    Thanks
    Rahul

Maybe you are looking for