How to write unicode to a file using MFC. I tried writing to a file using Cfile class but not sure on how to specify length of TCHAR also having trouble printing out new lines. A code snippet is welcome.
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
If you want an automatic conversion of \n to \r\n characters use CStdioFile and the methods ReadString/WriteString. Following example uses CFile: