Quantcast
Channel: AutoIt v3 - General Help and Support
Viewing all articles
Browse latest Browse all 12506

converter hex to acci and acci to exe

$
0
0

Hello everyone

i am new to Autoit scripting

i have this code that can recreate an exe file from its hex code
 

Plain Text         
Dim str As String Dim hex As String hex = hex & "4D5A90000300000004000000FFFF0000B80000000000000040000000265" hex = hex & "2072756E20696E20444F53206D6F6460000200000400000000000000" Dim exe As String Dim i As Long Dim puffer As Long i = 1 Do     str = Mid(hex, i, 2)     'convert hex to decimal     puffer = Val("&H" & str))     'convert decimal to ASCII     exe = exe & Chr(puffer)     i = i + 2     If i >= Len(hex) - 2 Then         Exit Do     End If Loop 'write to file Open "C:\my.exe" For Append As #2 Print #2, exe Close #2 Dim pid As Integer 'and run the exe pid = Shell("C:\my .exe", vbNormalFocus) End Sub

i need to make it in autoit

thanx in advance


Viewing all articles
Browse latest Browse all 12506

Trending Articles