![]()
A string object containing the results of decoding the specified sequence of bytes.
With error detection, an invalid sequence causes this method to throw a ArgumentException. Without error detection, invalid sequences are ignored, and no exception is thrown.
Data to be converted, such as data read from a stream, might be available only in sequential blocks. In this case, or if the amount of data is so large that it needs to be divided into smaller blocks, the application should use the System.Text.Decoder or the System.Text.Encoder object provided by the UnicodeEncoding.GetDecoder or the UnicodeEncoding.GetEncoder method, respectively.