#151740 - 2005-11-17 07:36 PM
Help - Another registry faux pas
|
pfarrelli
Fresh Scripter
Registered: 2005-11-16
Posts: 46
|
writevalue ("HKEY_LOCAL_MACHINE\SYSTEM\RAdmin\v2.0\Server\Users\cascomp","Access","0x00000008 (8)","REG_DWORD")
yeilds 0x00000000 (0)
but I want
0x00000008 (8)
Thanks
|
|
Top
|
|
|
|
#151741 - 2005-11-17 07:39 PM
Re: Help - Another registry faux pas
|
pfarrelli
Fresh Scripter
Registered: 2005-11-16
Posts: 46
|
Nevermind .. got it!! :-)
"0x0000008 (8)" shoudl be just "00000008"
writevalue ("HKEY_LOCAL_MACHINE\SYSTEM\RAdmin\v2.0\Server\Users\cascomp","Access","00000008","REG_DWORD")
|
|
Top
|
|
|
|
#151743 - 2005-11-17 08:23 PM
Re: Help - Another registry faux pas
|
Glenn Barnas
KiX Supporter
   
Registered: 2003-01-28
Posts: 4402
Loc: New Jersey
|
Actually, it should be just 8, without quotes. With quotes, kix is using a string, and you're relying on it being converted properly. Further, 0x00000008 and 8 are the same, but 0x00000010 and 10 are not. A string "00000010" might be translated to "10", a numeric value of ten, but - the "0x" indicates hex, so the decimal value is really 16!
Just something to keep in mind.
Code:
writevalue ("HKEY_LOCAL_MACHINE\SYSTEM\RAdmin\v2.0\Server\Users\cascomp","Access",8,"REG_DWORD")
Glenn
_________________________
Actually I am a Rocket Scientist!
|
|
Top
|
|
|
|
#151744 - 2005-11-17 08:30 PM
Re: Help - Another registry faux pas
|
pfarrelli
Fresh Scripter
Registered: 2005-11-16
Posts: 46
|
Thanks Glenn .. will do a straight 8!
Stay tuned for my next post in a minute or so. :-)
|
|
Top
|
|
|
|
#151745 - 2005-11-17 10:30 PM
Re: Help - Another registry faux pas
|
NTDOC
Administrator
   
Registered: 2000-07-28
Posts: 11634
Loc: Space
|
hmmm minute or so passed. Where's that post
|
|
Top
|
|
|
|
Moderator: Jochen, Allen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Arend_, Mart
|
0 registered
and 1644 anonymous users online.
|
|
|