01-15-2013 1:11 PM
Hi
i have a requirement regrading Excel formatting. i need to download data to excel with custom formatting , earlier i tried it with OLE programming, but it is taking so much time for download, can any one suggest me a better solutions...
01-15-2013 1:41 PM
Hi Nagesh,
Try the following Code,
CALL FUNCTION 'WS_DOWNLOAD'
EXPORTING
* BIN_FILESIZE = ' '
* CODEPAGE = ' '
FILENAME = 'C:\ BKPF.XLS'
FILETYPE = 'DAT'
* MODE = ' '
* WK1_N_FORMAT = ' '
* WK1_N_SIZE = ' '
* WK1_T_FORMAT = ' '
* WK1_T_SIZE = ' '
* COL_SELECT = ' '
* COL_SELECTMASK = ' '
* NO_AUTH_CHECK = ' '
* IMPORTING
* FILELENGTH =
TABLES
data_tab = it_bkpf
* FIELDNAMES =
* EXCEPTIONS
* FILE_OPEN_ERROR = 1
* FILE_WRITE_ERROR = 2
* INVALID_FILESIZE = 3
* INVALID_TYPE = 4
* NO_BATCH = 5
* UNKNOWN_ERROR = 6
* INVALID_TABLE_WIDTH = 7
* GUI_REFUSE_FILETRANSFER = 8
* CUSTOMER_ERROR = 9
* OTHERS = 10
This will download the contents of the internal table into Excel with the Horizantal and Vertical line.
Thanks,
Raghunadh.K
01-15-2013 5:36 PM
Hi Nagesh,
You can use XML transformation to download data to excel.
You can check the below links
http://www.abap-tutorials.com/2009/11/18/abap-program-to-create-formatted-excel-using-xml/#more-1021
Hope this helps
Reward points if helpful
01-16-2013 7:33 AM
Through XML also it is taking much time for even lesser records. The solution need to handle huge amount of data.....any alternate for that.
01-15-2013 7:45 PM
01-16-2013 12:57 PM
How much data are you exporting to Excel?
One option might be to look at Global Software which offers an Excel add-in for SAP. Essentially, eliminates the need to rekey/download info and reformat data in Excel while provide a live connection SAP.
You can read more here http://www.glbsoft.com/sap/spreadsheetserver.aspx
If your interested in testing this in your environment ping me directly or email me @ Eric.Smith@glbsoft.com
Best
Eric