Jump to content

Recommended Posts

Posted

I heard somebody talking about the Unicode effect if you save a .REG file as Unicode. Is there any difference whatsoever if my .REG file is saved as Unicode instead of ANSI under Windows XP?


Posted

Well, the registry can only hold keys and values in ANSI characters. It therefore follows logically, that any derivative of the registry should only contain those chars.

And if you save your .REG in unicode text, there's a good chance that there's some unicode chars in that file (intentionally, or unintentionally) - which is avoided if you save it as normal ANSI text.

Posted

The funny thing is though that if you export at .reg file in Windows XP it will export that file as UNICODE and not ANSI... There must be a reason for that. Ergo I believe that UNICODE is the most suitable format for .REG files, at least under windows xp, and especially if you use non-western european characters.

Posted

But what I do know is that if you have an English version of Windows (XP/2k/98/whatever) - saving your .REG in ANSI reduces the chance of unintended formatting characters getting left behind - therefore increasing the chances of your .REG being correct.

Posted

Too lazy!

It doesn't take a second in Registry Editor to use the drop down arrow in Save as type: to Win9x/NT4 Registration Files (*.reg), to save your exports as ANSI instead of Unicode.

The only noticeable difference will be that it'll start with REGEDIT4 instead of Windows Registry Editor Version 5.00

Posted

There is another difference. For example in the Unicode REG file each character in the values of REG_EXPAND_SZ and REG_MULTI_SZ is two bytes wide. For example the letter A is 0x0041 and not 0x41. In a version 4 ANSI reg file each character is a single byte wide. Here the Letter A IS 0x41.

Example:

Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Sample]
"String"="Superman"
"Binary"=hex:01,02,03,04,05,06,07,08
"DWORD"=dword:00004377
"Expandable String"=hex(2):25,00,55,00,53,00,45,00,52,00,00,00
"Multi-String"=hex(7):48,00,65,00,6c,00,6c,00,6f,00,00,00,00

REGEDIT4

[HKEY_CURRENT_USER\Test]
"String"="Superman"
"Binary"=hex:01,02,03,04,05,06,07,08
"DWORD"=dword:00004377
"Expandable String"=hex(2):25,55,53,45,52,00
"Multi-String"=hex(7):48,65,6c,6c,6f,00

Posted

well at least it's tidier....

i.e

On my next birthday i will be 0025 years old

On my next birthday i will be 25 years old

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...