StreamReader.CurrentEncoding Property

May 11, 2014

Gets the current character encoding that the current StreamReader object is using.

Namespace:  System.IO
Assembly:  mscorlib (in mscorlib.dll)

public virtual Encoding CurrentEncoding { get; }

Property Value

Type: System.Text.Encoding
The current character encoding used by the current reader. The value can be different after the first call to any Read method of StreamReader, since encoding autodetection is not done until the first call to a Read method.

Windows Phone OS

Supported in: 8.1, 8.0, 7.1, 7.0

Windows Phone

Show:
© 2014 Microsoft