Japanese (unicode?) text problem

Nicolas Cueto niconiko at gmail.com
Wed Sep 21 00:30:06 EDT 2016


​With Notepad++​, created a new file, pasted English and Japanese text, set
encoding to UTF-8,  then saved as .txt. (Confirmed the file by opening with
Windows' "Notepad".)

Next, in LC8.1 ran this button script:

on mouseUp
   put empty into field "indices"
   set the itemdel to quote
   put item 2 of the long name of this stack into tDataPath
   set the itemdel to "/"
   delete the last item of tDataPath
   put "/Data/bilingual.txt" after tDataPath
   put "file:" & tDataPath  into tURL
   put url tURL into field "indices"
end mouseUp

The text appears in the field, but with Japanese text garbled.

What am I doing wrong?

Thanks.

--
Nicolas Cueto



More information about the use-livecode mailing list