Possible Duplicate:
byte[] to string in c#
I have an byte array read from a stream. I'd like to convert it to a string.
This worked for me:
var str= new string(bytearr.Select(x=>(char)x).ToArray());
But I feel there's a better way to do it? Is there?