‎2010 Jun 02 4:23 PM
I am getting a field value like this
Lf_string = u2018abcdefghiu2019 . which might vary everytime . It could be different number of characters all the time ( upto 30 ).
I need to split it(for every 3 characters) and append it into the internal table
Then it should be like this ..
Itab[1]-f1 = u2018abcu2019
Itab[2]-f1 = u2018defu2019
Itab[3]-f1 = u2018ghiu2019
its not sticking me ..please help me .
‎2010 Jun 02 4:31 PM
Here is the sample code.
data: l_c(30) type c,
l_first type i,
l_last type i.
data: begin of itab occurs 0,
l_c1(3) type c,
end of itab.
l_c = 'abcdefghijkl'.
clear: l_first.
l_last = 3.
do.
itab-l_c1 = l_c+l_first(l_last).
append itab.
l_first = l_last.
l_last = l_last + 3.
if itab is initial.
exit.
endif.
enddo.
loop at itab.
write:/ itab-l_c1.
endloop.
‎2010 Jun 02 4:35 PM
Moderator message - Please do not ask or answer basic questions - thread locked Rob