Hi Dave,
Are there any way to put into the Registry a DWORD value ?
All tries I did put a char value.
Thanks in advance,
David de Argentina
RegistryWrite tip...
Moderator: Neosoft Support
-
- Posts: 1596
- Joined: Mon Apr 04, 2005 4:13 pm
- Location: Buenos Aires, Argentina
- Contact:
David de Argentina:
I did a Google search with "vbs registry write" ... and came up with a couple of useful references ...
http://itknowledgeexchange.techtarget.c ... -vbscript/
http://www.computerperformance.co.uk/ezine/ezine64.htm
Then did a Google search with "RegWrite" ... and came up with these ...
http://msdn.microsoft.com/en-us/library ... S.85).aspx
http://www.autoitscript.com/autoit3/doc ... gWrite.htm
http://www.pctools.com/guides/scripting ... =reference
http://www.devguru.com/Technologies/wsh ... Write.html
Basically, the syntax is very straight forward ... however, you need to know whether you are adding a "Value Name" or just changing its "Value" ... so a robust function would need to check this kind of thing first ... using RegRead ... trapping errors (for non-existent "Value Name") ... and proceed accordingly.
Note that one of the references points to "AutoIt" ... which can be used to make a (tiny) stand-alone exe that can be Run from NeoBook script ... passing variable data via the command line interface.
With the ability (in NeoBook v5.6) to use VB Scripts in NeoBook Functions Called inside your pub files ... you can exploit the facilities already available from this platform.Are there any way to put into the Registry a DWORD value ?
I did a Google search with "vbs registry write" ... and came up with a couple of useful references ...
http://itknowledgeexchange.techtarget.c ... -vbscript/
http://www.computerperformance.co.uk/ezine/ezine64.htm
Then did a Google search with "RegWrite" ... and came up with these ...
http://msdn.microsoft.com/en-us/library ... S.85).aspx
http://www.autoitscript.com/autoit3/doc ... gWrite.htm
http://www.pctools.com/guides/scripting ... =reference
http://www.devguru.com/Technologies/wsh ... Write.html
Basically, the syntax is very straight forward ... however, you need to know whether you are adding a "Value Name" or just changing its "Value" ... so a robust function would need to check this kind of thing first ... using RegRead ... trapping errors (for non-existent "Value Name") ... and proceed accordingly.
Note that one of the references points to "AutoIt" ... which can be used to make a (tiny) stand-alone exe that can be Run from NeoBook script ... passing variable data via the command line interface.
-
- Posts: 1596
- Joined: Mon Apr 04, 2005 4:13 pm
- Location: Buenos Aires, Argentina
- Contact:
Thanks Gaev,
But Neo 5.6 new features are not available for spanish users yet.
I remember a lot of problems when some user update Neo with another language patch...
And I think if Dave add to this action, a new parameter like "Type of Data" (DWORD, Char, etc) he could handle it very easy...
Greetings from Buenos Aires,
David de Argentina
But Neo 5.6 new features are not available for spanish users yet.
I remember a lot of problems when some user update Neo with another language patch...
And I think if Dave add to this action, a new parameter like "Type of Data" (DWORD, Char, etc) he could handle it very easy...
Greetings from Buenos Aires,
David de Argentina
David de Argentina:
You don't actually need v5.6 to exploit the capabilites of vbscript ... just load a "dummy" html document in a WebBrowser object ... then use BrowserExecScript to invoke it.
If Dave were to add this functionality ... presumably in NeoBook v5.7 ? ... whose Spanish version would be available AFTER v5.6 ...But Neo 5.6 new features are not available for spanish users yet.
And I think if Dave add to this action, a new parameter like "Type of Data" (DWORD, Char, etc) he could handle it very easy...
You don't actually need v5.6 to exploit the capabilites of vbscript ... just load a "dummy" html document in a WebBrowser object ... then use BrowserExecScript to invoke it.
-
- NeoSoft Team
- Posts: 5628
- Joined: Thu Mar 31, 2005 10:48 pm
- Location: Oregon, USA
- Contact:
If you're replacing an existing registry entry then NeoBook will attempt to convert the value you're writing to match the existing data type. New registry entries will be written as strings.
I don't expect that there will be more than a week or two delay between the release of the English version 5.6 and the other language versions.
I don't expect that there will be more than a week or two delay between the release of the English version 5.6 and the other language versions.
NeoSoft Support
Re: RegistryWrite tip...
David de Argentina wrote:Hi Dave,
Are there any way to put into the Registry a DWORD value ?
All tries I did put a char value.
Thanks in advance,
David de Argentina
I don't think you can set Dword in registry with just the Neobook Actions. But this VB Script works very well ... just change "MyProgram.exe" with the name of your Neobook application.
Code: Select all
Option Explicit
Dim Temp
'HKEY_CURRENT_USER = HKCU
'HKEY_LOCAL_MACHINE = HKLM
'HKEY_CLASSES_ROOT = HKCR
'HKEY_USERS = HKEY_USERS
'HKEY_CURRENT_CONFIG = HKEY_CURRENT_CONFIG
Temp = WriteReg("HKCU\SOFTWARE\Microsoft\Internet Explorer\MAIN\FeatureControl\FEATURE_BROWSER_EMULATION\MyProgram.exe","0","REG_DWORD")
Temp = ReadReg("HKCU\SOFTWARE\Microsoft\Internet Explorer\MAIN\FeatureControl\FEATURE_BROWSER_EMULATION")
'WScript.Echo Temp
Function WriteReg(RegPath, Value, RegType)
'Regtype should be "REG_SZ" for string, "REG_DWORD" for a integer,…
'"REG_BINARY" for a binary or boolean, and "REG_EXPAND_SZ" for an expandable string
Dim objRegistry, Key
Set objRegistry = CreateObject("Wscript.shell")
Key = objRegistry.RegWrite(RegPath, Value, RegType)
WriteReg = Key
End Function
Function ReadReg(RegPath)
Dim objRegistry, Key
Set objRegistry = CreateObject("Wscript.shell")
Key = objRegistry.RegRead(RegPath)
ReadReg = Key
End Function
.