CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3
  1. #1
    Join Date
    Sep 2007
    Posts
    117

    Read file with chinese characters

    Hi everyone,

    I'm trying to read a .txt file with Chinese characters.
    The file is currently saved with MicroSoft Notepad in UTF-16 LE format.
    Is there some way of reading this file to obtain a wchar_t * array?

    Thank you in advance.
    Last edited by rmirani; June 8th, 2020 at 11:29 AM.

  2. #2
    Arjay's Avatar
    Arjay is offline Moderator / EX MS MVP Power Poster
    Join Date
    Aug 2004
    Posts
    13,490

    Re: Read file with chinese characters

    Plenty of examples on google. Try searching for "how to read a unicode file in c++ example".

  3. #3
    VictorN's Avatar
    VictorN is offline Super Moderator Power Poster
    Join Date
    Jan 2003
    Location
    Hanover Germany
    Posts
    20,396

    Re: Read file with chinese characters

    Quote Originally Posted by rmirani View Post
    I'm trying to read a .txt file with Chinese characters.
    The file is currently saved with MicroSoft Notepad in UTF-16 LE format.
    Is there some way of reading this file to obtain a wchar_t * array?
    Maybe this article could help you?
    Victor Nijegorodov

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured