Skip to Content
author's profile photo Former Member
Former Member

excel with graphic for upload and download

Dear All,

Is it possible to store data in excel with graphics for eg.. boxes in (texts(for header or items) in SAP) and retreive the same data in excel format including graphics.

Regards,

Sonia

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

3 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Jan 16, 2009 at 06:05 AM

    Hi,

    Yes it is possible.

    check the foollowing program.

    &----


    *& Report ZDOWNLOAD_PROGRAM

    *&

    &----


    *&

    *&

    &----


    report zdownload_program.

    parameter : p_path type rlgrap-filename default 'C:\Pdata.xls'.

    data : gt_output type standard table of trdirt,

    wa_output type trdirt,

    p_filen type string.

    at selection-screen on value-request for p_path.

    clear p_path.

    call function 'F4_FILENAME'

    importing

    file_name = p_path.

    start-of-selection.

    select * from trdirt

    into table gt_output

    where name like 'Z%'

    or name like 'Y%'.

    end-of-selection.

    move : p_path to p_filen.

    call function 'GUI_DOWNLOAD'

    exporting

    • BIN_FILESIZE =

    filename = p_filen

    filetype = 'ASC'

    • APPEND = ' '

    write_field_separator =

    cl_abap_char_utilities=>horizontal_tab

    • HEADER = '00'

    • TRUNC_TRAILING_BLANKS = ' '

    • WRITE_LF = 'X'

    • COL_SELECT = ' '

    • COL_SELECT_MASK = ' '

    • DAT_MODE = ' '

    • CONFIRM_OVERWRITE = ' '

    • NO_AUTH_CHECK = ' '

    • CODEPAGE = ' '

    • IGNORE_CERR = ABAP_TRUE

    • REPLACEMENT = '#'

    • WRITE_BOM = ' '

    • TRUNC_TRAILING_BLANKS_EOL = 'X'

    • WK1_N_FORMAT = ' '

    • WK1_N_SIZE = ' '

    • WK1_T_FORMAT = ' '

    • WK1_T_SIZE = ' '

    • WRITE_LF_AFTER_LAST_LINE = ABAP_TRUE

    • IMPORTING

    • FILELENGTH =

    tables

    data_tab = gt_output

    • FIELDNAMES =

    exceptions

    file_write_error = 1

    no_batch = 2

    gui_refuse_filetransfer = 3

    invalid_type = 4

    no_authority = 5

    unknown_error = 6

    header_not_allowed = 7

    separator_not_allowed = 8

    filesize_not_allowed = 9

    header_too_long = 10

    dp_error_create = 11

    dp_error_send = 12

    dp_error_write = 13

    unknown_dp_error = 14

    access_denied = 15

    dp_out_of_memory = 16

    disk_full = 17

    dp_timeout = 18

    file_not_found = 19

    dataprovider_exception = 20

    control_flush_error = 21

    others = 22

    .

    if sy-subrc <> 0.

    message id sy-msgid type sy-msgty number sy-msgno

    with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.

    endif.

    Regards

    Rajesh Kumar

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 16, 2009 at 06:10 AM

    hi sonia

    the fm ALSM_EXCEL_TO_INTERNAL_TABLE can be used to upload excel file and you can download to an excel sheet using the function module GUI_DOWNLOAD.

    hope this helps

    regards

    Aakash Banga

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 16, 2009 at 06:41 AM

    Hi,

    Refer below FMs.

    ALSM_EXCEL_TO_INTERNAL_TABLE

    GUI_UPLOAD

    GUI_DOWNLOAD

    ALSM_EXCEL_TO_INTERNAL_TABLE and GUI_UPLOAD both FMs you can use upload Excel file.

    Regards

    Md.MaahboobKhan

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.