How to correctly open UTF-8 files in RichTextBox?
<p>I have a question. This code open fine the txt files with english text, but when I trying to open the txt files with cyrillic text... the cyrillic symbols are "squares". Is it possible to resolve this problem?</p>

<pre><code>        string fileData = openFileDialog1.FileName;
        StreamReader sr = new StreamReader(fileData);
        richTextBox.Text = sr.ReadToEnd();
        sr.Close();

        SavedFile = saveFileDialog1.FileName;
        dataTextBox.SaveFile(SavedFile, RichTextBoxStreamType.PlainText);
</code></pre>

<p>Solution:</p>

<pre><code>        string fileData = openFileDialog1.FileName;
        StreamReader sr = new StreamReader(fileData, Encoding.Default);
        richTextBox.Text = sr.ReadToEnd();
        sr.Close();
</code></pre>
