cancel
Showing results for 
Search instead for 
Did you mean: 

how to export the text edit data to excel file without splitting the data in excel file?

former_member201541
Participant
0 Kudos

how to export the text edit data to excel file without splitting the data in excel file?

I have a requirement in SAP HR where in the appraiser can add comments in the area given and can export that to excel file. Currently the file is getting exported but the comments getting split into deifferent rows.

I want the entire comment to be fit in one row.

Please help.

Thank you

Accepted Solutions (0)

Answers (2)

Answers (2)

former_member212124
Active Participant
0 Kudos

Hi Ajinkya,

As per my understanding you don't want the text entered(text edit) to be shown in different rows in excel.Right??

1) then you just have to replace all the '#' symbols in you text with space in text edit variable.

2) then finally condense it according to your requirement.

please ask if any doubts

Thanks,

vidyasagar

former_member201541
Participant
0 Kudos

Thanks Vidyasagar,

Yes right. Can u please elaborate more on the solution u given

former_member212124
Active Participant
0 Kudos

Hi,

if your text edit value is stored in 'lv_string' variable.

then before exporting the value to excel you have to remove CL_ABAP_CHAR_UTILITIES=>NEWLINE

that is '#' from the variable lv_string.

for that use code some thing like this.

REPLACE ALL OCCURRENCES OF CL_ABAP_CHAR_UTILITIES=>NEWLINE in lv_string WITH space.


I think this will do the trick.

former_member197475
Active Contributor
0 Kudos

Hi Ajinkya,

It will be much favor, if you paste your code here.

Also do analysis with the methods of the class cl_abap_char_utilities.

BR,

RAM.