2007 Mar 02 10:16 AM
2007 Mar 02 10:21 AM
Hi Vinay,
Try the function module STRING_REVERSE.
Works perfectly fine.
Rgds,
Aditya
2007 Mar 02 10:17 AM
use FM:
STRING_REVERSE
Usage:
CALL FUNCTION 'STRING_REVERSE'
EXPORTING
string = name
lang = sy-langu
IMPORTING
rstring = re_name.
2007 Mar 02 10:20 AM
2007 Mar 02 10:20 AM
Hello,
USe the FM <b>STRING_REVERSE</b>
Check the sample code:
report YXYZ.
parameter S(10) type C.
data S1(10) type C.
<b>call function 'STRING_REVERSE'
exporting
STRING = S
LANG = 'E'
importing
RSTRING = S1.</b>
if S = S1.
write 😕 S, 'is palindrom'.
else.
write 😕 S, 'is not palindrom'.
endif.
Vasanth
Message was edited by:
Vasanth M
2007 Mar 02 10:21 AM
Hi Vinay,
Try the function module STRING_REVERSE.
Works perfectly fine.
Rgds,
Aditya
2007 Mar 02 10:28 AM
data: c(5) value 'ABCDE',l type i, i type i value -1.
data: str(5).
l = strlen( c ).
do l times.
i = i + 1.
l = l - 1.
STR + i(1) = C + l(1).
enddo.
write: str.