What is the best (fastest) way to convert a string stored in a binary array to a string object?
Printable View
What is the best (fastest) way to convert a string stored in a binary array to a string object?
At long last after hours of research I have found the stupid answer.
To convert a byte array to string use and vice-versa ;) :
Why is .NET stuff like this so stupidly easy but such a pain in the axe to find documented? :confused::mad:Code:dim enc As New System.Text.ASCIIEncoding
dim bytes() As Byte
dim strMessage as String
strMessage = "Hello World"
bytes = enc.GetBytes(strMessage)
strMessage = enc.GetString(bytes)
Rats,
pjp