So here, I am finishing a Chinese App and wanting to save the unicode in a fld to a .txt file, and I just get gibberish...eg
set the defaultFolder to specialFolderPath("Documents")
put the unicodetext of fld "scrollfield" into URL ("file:mylist.txt")
or
set the defaultFolder to specialFolderPath("Documents")
set the unicodetext URL ("file:mylist.txt") to the unicodetext of fld "scrollfield"
and the file won't save.
Any ideas of my syntax that won't let me save unicode field into a .txt file?
Scott
saving unicodetext
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
Re: saving unicodetext
Hi Scott,
Try this:
And when it's time to read, don't forget to uniEncode the content first.
Hope it helps...
Best,
~ Ender Nafi
Try this:
Code: Select all
put uniDecode(the unicodeText of fld "scrollfield", "utf8") into URL ("file:mylist.txt")
Hope it helps...
Best,
~ Ender Nafi
~... together, we're smarter ...~
__________________________________________
macOS Sierra • LiveCode 7 & xCode 8
__________________________________________
macOS Sierra • LiveCode 7 & xCode 8
-
- Posts: 125
- Joined: Sat Jan 31, 2009 12:01 am
Re: saving unicodetext
that would have taken me another 10 hours just to figure that one out! thanks!
Scott
Scott