2009 Jun 03 2:27 PM
Dear Experts,
I have to download a file as excel workbook in background on application server.
I have used open / close data set using that I am able to download .CSV and Tab Delimated file(with extension as .xls) but not excel workbook.
Regards and Thanks,
Vikas
Dear Experts,
I have to download a file as excel workbook in background on application server.
I have used open / close data set using that I am able to download .CSV and Tab Delimated file(with extension as .xls) but not excel workbook.
Regards and Thanks,
Vikas
2009 Jun 03 2:32 PM
Hi, Patel
Please don't use All Caps in Subject Line
Please Have a Look [Rules of Engagement|https://wiki.sdn.sap.com/wiki/display/HOME/RulesofEngagement]
Kind Regards,
Faisal
2009 Jun 04 4:48 AM
Thanks Faisal,
I have'nt seen rules of engagement before you told me the same.
Regards ,
Vikas
2009 Jun 04 5:24 AM
Hi Vikas,
what i understood is , u hav a excel file on presentation server (desktop) and want to upload it to the appln server. if so do the following :
step one : save the excel file with all the data u wanted in it.
step two : save as the excel file in tab delimited format.
step three : save as the tab delimited file in ansi .txt format.
Now cg3z to upload the text file (.txt) in appln server .
open the file as below:
DATA: begin of itab,
col1 type <>,
col2 type <>,
end of itab.
DATA : wa_itab like itab.
DATA: wa(100) TYPE c,
xeof(1) TYPE c.
PARAMETERS: p_file(30) TYPE c DEFAULT 'appln server path .txt' LOWER CASE
OBLIGATORY,
OPEN DATASET <p_file> FOR INPUT IN TEXT MODE
ENCODING DEFAULT.
IF sy-subrc NE 0.
WRITE : ' error opening the file "
EXIT.
ELSE.
DO.
READ DATASET p_file INTO wa.
IF sy-subrc NE 0.
xeof = 'X'.
EXIT.
ENDIF.
IF sy-subrc EQ 0.
PERFORM split_data.
ELSE.
EXIT.
ENDIF.
ENDDO.
CLOSE DATASET p_file .
FORM split_data .
SPLIT wa AT cl_abap_char_utilities=>horizontal_tab
INTO wa_itab-col1 wa_itab-col2 wa_itab-col3.
APPEND wa_itab TO gi_itab.
ENDFORM. " SPLIT_DATA
2009 Jun 04 9:45 AM
Dear Venkat,
Thanks for replaying.
I am not having excel file on presentation server, I want to download data from internal table as excel workbook(spreadsheet) in background on presentation server.
I am able to download the data from internal table as .CSV or Tab delimated file, but not able to download the data in proper excel workbook format(spreadsheet).
Regards,
Vikas
2009 Jun 04 11:40 AM
Hi Vikas,
I have also searched a lot on this for one of my assignment. But i couldn't find any. Acc to me, its not possible to download an excel file on application server.
Regards
Natasha Garg
| User | Count |
|---|---|
| 3 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |