deathday Posted January 21, 2009 Posted January 21, 2009 (edited) hey every one is there a code in autoit which can convert hex to ascii , like in vb which has a code asciitohex and hextoascii ,If there is tell me please? Edited January 21, 2009 by deathday
Bert Posted January 21, 2009 Posted January 21, 2009 Use _HexToString thenStringToASCIIArray The Vollatran project My blog: http://www.vollysinterestingshit.com/
darzanmihai Posted January 21, 2009 Posted January 21, 2009 hey every one is there a code in autoit which can convert hex to ascii , like in vb which has a code asciitohex and hextoascii ,If there is tell me please? or, something I found on the forum: $hex="36 35";hex $Hex2Ascii = ChrH($hex);Ascii $Ascii2Hex = AscToHex($Hex2Ascii);Hex $Char = Chr($Hex2Ascii);char MsgBox(0,$hex,$Hex2Ascii&@CRLF&$Ascii2Hex&@CRLF&$Char) Func ChrH($strString) ;hex to ascii Local $ch="" $A1 = StringSplit($strString, " ") For $i = 1 To $A1[0] $Ch &= Chr(Dec($A1[$i])) Next Return $Ch endFunc Func AscToHex($strString) ;ascii to hex Local $ah="" For $i = 1 To StringLen($strString) If StringLen(Hex(Asc(StringMid($strString, $i, 1)),2)) = 1 Then $ah &= "0" & Hex(Asc(StringMid($strString, $i, 1))) Else $ah &= Hex(Asc(StringMid($strString, $i, 1)),2) EndIf If $i <> StringLen($strString) Then $ah &= " " Next Return $ah endFunc I do not like stupid and idiot people that write idiot things...If you are one, do not write.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now