Binary to String
System.Text.ASCIIEncoding enc = new System.Text.ASCIIEncoding();if you want to make sure that there is no data loss then use Base64 Encoding
string str = enc.GetString(MyByteArray);
Base64 Encoding :- converts binary data to plain text using 64 case-sensitive, printable ASCII characters: A-Z, a-z, 0-9, plus sign (+) and forward slash (/), and may be terminated with 0-2 "padding" characters represented by the equal sign (=).
Convert.ToBase64String(myByteArray);
when you are working with picture it will be good to use Base64 conversion so you could make sure that there is no data lose
Got more useful information about binary to string conversion in C#.
ReplyDeleteASP to ASP.Net Migration
Convert ASP to ASP.Net