‎2009 Apr 27 9:07 AM
Hi.
I got the following code and I really don't know what it does or even why. All I know It's not UC enabled ( since it's uxinf the type x).
I was thinking I might be converting from ascii representation to text or something like that but I'm not that sure.
FORM TRANSLATE_FIELD USING STRING_TRAN
CHANGING STRING1.
DATA: STRING(255),
len1(3) type i,
LEN(3) TYPE I,
NUM(3) TYPE I,
I(3) TYPE I.
DATA: C VALUE 'A',
X TYPE X.
FIELD-SYMBOLS:<fc> type c.
STRING = STRING_TRAN.
len1 = strlen( STRING ).
LEN = 0.
NUM = 0.
while len < len1.
i = STRING+len(3).
move i to x.
assign x to <fc> casting type c.
move <fc> to c.
MOVE C TO STRING1+NUM.
len = len + 3.
NUM = NUM + 1.
endwhile.
ENDFORM. " TRANSLATE_FIELD
Thanks
Ariel
‎2009 Apr 27 9:13 AM
Hi ,
Display the code in change mode .On top u will see the tab Goto.In this u will see the Attributes.
Click on attributes and it will poen a popup window.In this window at the bottom u will see the 'Unicode checks active' .
You need to check it in order to make this code unicode compatible.
Regards,
Anuj
‎2009 Apr 27 9:18 AM
‎2009 Apr 27 11:08 AM
Hi.
I want to make this small code UC enabled. Since there is a move of TYPE x into char this is not OK at the mopment.
the problem is I don't really know or understand how to convert itr to UC enabled program.
You can notice it takes clusters of 3 chars (bytes ?) long and convert them to char.
For example 101 = e 100 = d 099 = c.... 😆 101099101 -> ece .
Thanks
Ariel
‎2010 May 23 8:17 AM