G
Guest
Hello,
I want to read a text file which contains French charactor, then modify some of the
sentence, save it as a new text file.
But I found the new text file lost all the French charactors.
Anybody can help me?
Thanks,
Yongjian
My code:
StreamReader sr = new StreamReader(stSource,Encoding.UTF8);
StreamWriter sw = new StreamWriter(stDestination,false, Encoding.UTF8);
while ((stLine = sr.ReadLine())!=null)
{
// add something to the stLine, then write it to a new file
sw.WriteLine(stLine);
}
sr.Close();
sw.Close();
I want to read a text file which contains French charactor, then modify some of the
sentence, save it as a new text file.
But I found the new text file lost all the French charactors.
Anybody can help me?
Thanks,
Yongjian
My code:
StreamReader sr = new StreamReader(stSource,Encoding.UTF8);
StreamWriter sw = new StreamWriter(stDestination,false, Encoding.UTF8);
while ((stLine = sr.ReadLine())!=null)
{
// add something to the stLine, then write it to a new file
sw.WriteLine(stLine);
}
sr.Close();
sw.Close();