Jump to content

Recommended Posts

Friends want to add the same.

Windows Registry Editor Version 5.00


I tried every way, do you have any idea?

I've tried all the codes


#include <String.au3>

;~ $sString1 = 'C:\Users\USER\Desktop'
$sString = 'D:\Download'

;RegWrite('HKCU\Software\DownloadManager', 'LocalPathW', 'REG_BINARY', StringToBinary('D:\Download'))
;~ RegWrite('HKCU\Software\DownloadManager', 'LocalPathW', 'REG_BINARY', Binary('0x' & $sString))

;~ RegWrite('HKCU\Software\DownloadManager', 'LocalPathW', 'REG_BINARY', $sString)

$StConvertHex = _StringToHex("D:\Download")
;~ RegWrite("HKCU\Software\DownloadManager", "LocalPathW", "REG_BINARY", $StConvertHex)
;~ RegWrite("HKCU\Software\DownloadManager", "LocalPathW", "REG_BINARY", "0x" & $StConvertHex)
;~ RegWrite("HKCU\Software\DownloadManager", "LocalPathW", "REG_MULTI_SZ", "0x" & $StConvertHex)
RegWrite('HKCU\Software\DownloadManager', 'LocalPathW', 'REG_BINARY', Binary('0x' & $StConvertHex))


Edited by youtuber
Link to post
Share on other sites

Here how to convert string to fit registry binary write :

#include <Constants.au3>
#include <String.au3>

Local $sHex = _StringToHex("D:\Download")
Local $sFinal = "0x"
For $i = 1 to StringLen ($sHex)/2
  $sFinal &= StringMid ($sHex,$i*2-1,2) & "00"
MsgBox ($MB_SYSTEMMODAL,"",$sFinal)
Regwrite ('HKCU\Software\DownloadManager', 'LocalPathW', 'REG_BINARY', $sFinal)


Edited by Nine
Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    No registered users viewing this page.

  • Create New...