In SAP ABAP , when I use Call method (util class)=>GUI_DOWNLOAD to XLSX – it is displaying value of VEKP-EXIDV field value say ‘344230E+15’

  • internal table for download is Char field(for either long number or decimal field)
  • ALV fieldcatalog eventhough matched with -fieldstructure(char 20 via Domain/Data definition) , it is issue during XLSX extracted file.

Note: SAP_CONVERSION_TO_XLS_FORMAT call as well din’t resulted as expected.

Please recommend AS-IS value of long string(more characters) display during XLS download process in SAP ABAP/CRM Customized Reports.

In SAP ABAP , when I use Call method (util class)=>GUI_DOWNLOAD the issue during download file is as described below.

  • Packing# (VEKP-EXIDV) is assigned to Char 20 while transfer to XLSX file/ALV display log via report.

-The excel file receives value as ‘344230E+15’ instead of ‘34423000065007790’ which influence invalid detail during uploading the same file(for follow up process after download).

I am looking to get VALID packing number to match with SAP Table(PASS scenario).

  • CALL METHOD cl_gui_frontend_services=> gui_download.
    Exporting
    Filename = lv_path
    Filetype=”ASC”
    Changing
    Data_tab = lt_download “(1st column as long text and incorrectly displayed in XLXS file)

EndMethod.

the display of long text(valid Table value of VEKP-> field EXIDV) column in Excel(different than when opened as CSV/TXT file) ,while downloaded an internal table values to Excel file.

  • You didn’t describe enough your program so please post a minimal reproducible example. Based on what you say, it seems that you are not generating a true XLSX file (you are eventually just appending .xlsx to the file name) but a CSV file, so it’s quite normal that long numbers are initially expressed with components, as per Excel design (you can find many explanations in the Excel forums). It’s just a guess, as I said I don’t have enough information to be sure.

    – 

  • Do you know about the free library ABAP2XLSX? It allows you to build native Excel files and gives you a lot of control, including format settings for cells.

    – 




Leave a Comment