Jump to content

REG_BINARY : the change that killed me...


Recommended Posts

with autoit v3.3.0.0, this change happens:

Changed: RegRead() and RegWrite() no longer use hex strings for REG_BINARY types - native binary datatypes are enforced.

Minor change, big effects.

ok for regwrite, it's easy to scan source code and replace for example : regwrite(....,"REG_BINARY","0010002") with

regwrite(....,"REG_BINARY",binary("0x0010002"))

But for regread, how to be sure to make all changes that are needed ? scanning all regread order... and then ? guess that it retrieves binary ? and what happens if you have not the registry entry on the PC you are using for writing autoit source code ?

and the adaptation will look sooo fun: something like :

regread("key","value") ---> stringmid(string(regread("key","value")),2) (I'm even not sure this is good)

And this minor change is for what ?? who knows.... :)

I like Autoit... yes, really a good tool.

But sometimes, I hate it... guess why...

Edited by sksbir
Link to comment
Share on other sites

Just Hex is enough :)

 

Hex(Binary("0x1234567890ABCDEF"))
-->
$value = Hex(RegRead("KEY", "VALUE"))
$value = RegRead("KEY", "VALUE")
If @extended==3 Then $value = Hex($value) ; for Binary data, @extended is 3
Edited by Jon

*GERMAN* [note: you are not allowed to remove author / modified info from my UDFs]My UDFs:[_SetImageBinaryToCtrl] [_TaskDialog] [AutoItObject] [Animated GIF (GDI+)] [ClipPut for Image] [FreeImage] [GDI32 UDFs] [GDIPlus Progressbar] [Hotkey-Selector] [Multiline Inputbox] [MySQL without ODBC] [RichEdit UDFs] [SpeechAPI Example] [WinHTTP]UDFs included in AutoIt: FTP_Ex (as FTPEx), _WinAPI_SetLayeredWindowAttributes

Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...