I try to conver hex value to string by using Byteconverter.lib and I had no more idea. Need some help.
here is my code:
Sub hex_convertion
Dim BConv As ByteConverter
Dim Bytes() As Byte
Dim Str As String
RPM.Text = txtLog.Text.SubString2(6,11)
RPM.Text = RPM.Text.Replace(" ","")
If RPM.Text.Length > 0 Then
Bytes = BConv.HexToBytes(RPM.Text)
Str = BConv.StringFromBytes(Bytes,"ASCII")
Msgbox(str, "RPM")
End If
End Sub
tnx
here is my code:
Sub hex_convertion
Dim BConv As ByteConverter
Dim Bytes() As Byte
Dim Str As String
RPM.Text = txtLog.Text.SubString2(6,11)
RPM.Text = RPM.Text.Replace(" ","")
If RPM.Text.Length > 0 Then
Bytes = BConv.HexToBytes(RPM.Text)
Str = BConv.StringFromBytes(Bytes,"ASCII")
Msgbox(str, "RPM")
End If
End Sub
tnx
Last edited: