unicode to hexadecimal
Posted: Fri May 03, 2019 10:12 am
Hi All
I want to convert unicode Chinese character to hex value. I can use the following to convert english to hex value.
put charToNum("P") into tNum
answer baseConvert(tNum,10,16) ; return 70
If I use a Chinese character "δΈ" in the above it will return "3F". which is not correct. The correct value is "\u4E2D".
Please advise how can I make it!
Regards
Terry Ho
I want to convert unicode Chinese character to hex value. I can use the following to convert english to hex value.
put charToNum("P") into tNum
answer baseConvert(tNum,10,16) ; return 70
If I use a Chinese character "δΈ" in the above it will return "3F". which is not correct. The correct value is "\u4E2D".
Please advise how can I make it!
Regards
Terry Ho