hello guys))
Advice please - how to set the stream encoding? (to read a text file)
I use this code -
StreamReader stream1 = new StreamReader(fs);
System.Text.Encoding code = stream1.CurrentEncoding;
StreamReader stream2 = new StreamReader(fs,code);
while ((i = stream2.ReadLine()) != null)
{
label1.Text = label1.Text + i;
}
stream2.Close();
but in label1.text I have only numbers and weird characters ((
tell me - where's the mistake?
Thank you in advance)