Converting String to Byte Arrays
-
Hi, I am trying to convert a unicode string containing characters with different code page (Basically a set of hex data stored in a string). When I tried to convert them they somehow get mixed up by VB. Does anybody know of a low level way of converting strings to Byte array? I am using VB6 by the way. Thanks. SDE
-
Hi, I am trying to convert a unicode string containing characters with different code page (Basically a set of hex data stored in a string). When I tried to convert them they somehow get mixed up by VB. Does anybody know of a low level way of converting strings to Byte array? I am using VB6 by the way. Thanks. SDE
A quick Google for "VB6 convert string byte array" comes up with:
' Convert string into a byte array:
Dim b() As Byte
b = "This is the String"' Add null termination:
Redim Preserve b(0 To Ubound(b) + 2) As ByteRageInTheMachine9532 "...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome