Here is my Hex to String function
Hex to String Function Code:
Public Function HexToString(ByVal HexToStr As String) As String Dim strTemp As String Dim strReturn As String Dim I As Long For I = 1 To Len(HexToStr) Step 3 strTemp = Chr$(Val("&H" & Mid$(HexToStr, I, 2))) strReturn = strReturn & strTemp Next I HexToString = strReturn End Function
and here is my String to Hex function
String to Hex Function Code:
Public Function StringToHex(ByVal StrToHex As String) As String Dim strTemp As String Dim strReturn As String Dim I As Long For I = 1 To Len(StrToHex) strTemp = Hex$(Asc(Mid$(StrToHex, I, 1))) If Len(strTemp) = 1 Then strTemp = "0" & strTemp strReturn = strReturn & Space$(1) & strTemp Next I StringToHex = strReturn End Function
I hope they help everyone![]()





Reply With Quote