I had a question about the text-file reading, I just begin to learn this programming environment.
Environmenet: Visual Studio.net 2003
Windows Form Applications (.net C++)
I want to read a text file and put the content into a textbox by using the following statment:
But it seems that there happend a encoding problem during the reading action. The file I want to read is a text-file in Chinese. After running the programme, the characters in the textbox are totally unreadable. It is told that the streamreader is reading a text file with UTF-8 encoding. So, how could read a text file with the Eastern Characters? Thanks very much!Code:String* inp; StreamReader* sr = File::OpenText("C://...//xyz.txt"); inp = sr->ReadToEnd(); textBox1->Text = inp;