Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Convert from ASCII to UTF-8
Message
 
 
To
21/08/2009 12:10:51
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP2
Miscellaneous
Thread ID:
01419559
Message ID:
01419563
Views:
72
This message has been marked as the solution to the initial question of the thread.
>I am reading in a file that has double-byte characters and parsing it. I then write the file to output. I am using FOPEN, FREAD, FPUTS, and FCLOSE to open, read and parse the file and then close. After closing I use the following command:
>
>
>=STRTOFILE(FILETOSTR(lcFileName),lcFileName,4)
>
>
>This encodes the file as UTF-8. However, the line contents are not being converted to UTF-8. This only marks the file as UTF-8. How do I convert each line and save into UTF-8 format? The FREAD and FPUTS commands seem to only work with ASCII.
>
>Thanks.

Check STRCONV function in Help.

9
Converts double-byte characters in cExpression to UTF-8
If it's not broken, fix it until it is.


My Blog
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform