decoding hex

  • 159
    Posts
    20
    Years
    how do i decode hex values into letters?? i found this

    Dim HexString As String
    Dim OneChar As String
    Dim TwoChar As String
    Dim NewText As String

    Open "Data.Enc" For Input As #1

    While Not EOF(1)
    Line Input #1, HexString
    For I = 1 To Len(HexString)
    OneChar = (Mid$(HexString, I, 1))
    If OneChar = "G" Then
    NewText = Chr(Val("&H" + TwoChar))
    DecodedString = DecodedString & NewText
    OneChar = ""
    TwoChar = ""
    Else
    TwoChar = TwoChar & OneChar
    End If
    Next I
    Open "Converted.dat" For Output As #2
    Print #1, DecodedString
    DecodedString = ""
    Wend


    --But i don't understand how to use it. i want like the value BB to equal A and BC to equal B and so on. where would i put that in up there? thnx
     
    that's explaining what hex is, and i already know what hex is? and that nothin to do with vb
     
    Back
    Top