>>Hi All
>>
>>I am receiving text (TXT) files from a 3rd party entity. I read the file in using FILETOSTR(), amend it, and then write it out to another TXT file using STRTOFILE(). Someone has now asked me what character set we are using for the output file. How do I find that out or answer this question?
>>
>>TIA
>
>STRTOFILE() generates pure TXT and uses that charset what is set in Control Panel->Region and Language->Administrative->Current Language for non-Unicode programs.
>In most cases it is Windows-1252 (in my case it is Windows-1251).
>
>That is true if you didn't use STRCONV() or API function to convert the chars.
Nope. If any codepage translation it's done at input (keyboard) level. StrToFile() just writes the bytes as they come.
It does not generate
text files.
lcx =filetostr(HOME()+'VFP9.exe')
STRTOFILE(lcx,GETENV("TEMP")+'\VFP9.exe')
creates a copy of VFP.9 exe
Lutz
Words are given to man to enable him to conceal his true feelings.
Charles Maurice de Talleyrand-Périgord
Weeks of programming can save you hours of planning.
OffThere is no place like [::1]