Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

down load into excel file

Former Member
0 Likes
736

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 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.

5 REPLIES 5
Read only

Former Member
0 Likes
707

Hi,

In a report once you generate and ALV output, you can alwys download it to EXCEL file or WORD file from the button available there...

but this is done only if u use ALV output.

<b>

Reward points for helpful answer,</b>

Regards,

Tejas

Read only

Former Member
0 Likes
707

hi teja,

thanks for the reply.i know that v can download from ALV output. But the length of the file in word documnt should not exceed 156 character each line.

tell me is it possible bcz as i mentioned earlier the word document will be sent to RBI format.

Regards,

Alson

Read only

Former Member
0 Likes
707

Hi,

I think u can do it by populating the data into ur internal table ina string of length 156. Append the whole data to th eitab, and then use this for downlaoding purpose.

sudha

Read only

Former Member
0 Likes
707

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

Read only

Former Member
0 Likes
707

Hi..,

hope it helps u...

you can use ole object and have a referrence to the following code&#65306;

DATA: L_COLUMN TYPE OLE2_OBJECT, " COLUMN OBJECT

L_FONT TYPE OLE2_OBJECT. " FONT OBJECT

L_COLUMN = 1.

  • set column properties

CALL METHOD OF V_EXCEL 'Columns' = L_COLUMN

EXPORTING

#1 = L_SERIAL.

PERFORM FRM_ERR_HDL.

SET PROPERTY OF L_COLUMN 'ColumnWidth' = L_WIDTH.