RegObj.dll - Newbie Example 
Author Message
 RegObj.dll - Newbie Example

Hi,
I new to scripting/programming. Can someone post an example VBS script that
uses this control? I just need some basics and can work from there. I am
looking to delete registry keys and read registry keys? Also, is there a way
to silently register this control? Thanks in advance for the help.

Lando



Mon, 29 Sep 2003 21:14:13 GMT  
 RegObj.dll - Newbie Example
The good examples are on Clarence's site (http://cwashington.netreach.net) which unfortunately is
temporarily offline.

Check the regobj.doc file that came with the component...  The examples are for VB but translate
easily to VBScript...

--
Michael Harris
Microsoft.MVP.Scripting
--

Please do not email questions - post them to the newsgroup instead.
--

Quote:

> Hi,
> I new to scripting/programming. Can someone post an example VBS script that
> uses this control? I just need some basics and can work from there. I am
> looking to delete registry keys and read registry keys? Also, is there a way
> to silently register this control? Thanks in advance for the help.

> Lando



Tue, 30 Sep 2003 00:54:43 GMT  
 RegObj.dll - Newbie Example


Fri, 19 Jun 1992 00:00:00 GMT  
 RegObj.dll - Newbie Example
I'm new to programing. I can't seem to get the script below coverted to VBS.
Can anyone help? I really don't need to access a remote registry. The local
registry is what I want to work with.

Thanks for all the help. You guys have been great!
Lando

***********************************************
Dim WSHShell
 Set WSHShell = WScript.CreateObject("WScript.Shell")

Dim objRemoteRegistry

'See if we can obtain the Registry of machine Lab1:
Set objRemoteRegistry = RemoteRegistry("IFORKASH-2K")

'Print out all the subkeys of the HKEY_CLASSES_ROOT on the Lab1 machine
Dim objSubKey As RegKey
Dim objRegRootKey As regKey

var ProxyOnOff =
WshShell.RegRead("HKEY_USERS\\ThisUser\\Software\\Microsoft\\Windows\\Curren
tVersion\\Internet Settings\\ProxyEnable")

var ProxyType = typeof(ProxyOnOff)

Set objRegRootKey = objRemoteRegistry.RegKeyFromHKey(HKEY_CLASSES_ROOT)

For Each objSubKey In objRegRootKey.SubKeys
Debug.Print objSubKey.Name
Next objSubKey
************************************************************

Quote:
> The good examples are on Clarence's site (http://cwashington.netreach.net)

which unfortunately is
Quote:
> temporarily offline.

> Check the regobj.doc file that came with the component...  The examples

are for VB but translate
Quote:
> easily to vbscript...

> --
> Michael Harris
> Microsoft.MVP.Scripting
> --

> Please do not email questions - post them to the newsgroup instead.
> --




Quote:
> > Hi,
> > I new to scripting/programming. Can someone post an example VBS script
that
> > uses this control? I just need some basics and can work from there. I am
> > looking to delete registry keys and read registry keys? Also, is there a
way
> > to silently register this control? Thanks in advance for the help.

> > Lando



Tue, 30 Sep 2003 02:29:56 GMT  
 RegObj.dll - Newbie Example
No offense, but you have a pretty weird combination of vbscript/vb/jscript ;-)...

Here's just a CScript hosted vbscript example for remote registry access with RegObj.  You must be
logged on with a domain account that is also in the Administrators group on the remote NT server
machine.

Dim StdIn, StdOut
Dim objRegistry, objRemoteRegistry
Dim objRegRootKey, objSubKey

Const HKEY_CLASSES_ROOT = &H80000000

'===
' uses stdin/stdout streams to guarantee execution under WScript will fail
' (unless you like clicking OK on about a zillion message boxes ;-)...
'===
Set StdIn = WScript.StdIn
Set StdOut = WScript.StdOut

Set objRegistry = CreateObject("RegObj.Registry")
'===
' fully qualified domain names are faster, but NETBIOS name works too...
'===
Set objRemoteRegistry = _
  objRegistry.RemoteRegistry("servername.companyname.com")

Set objRegRootKey = objRemoteRegistry.RegKeyFromHKey(HKEY_CLASSES_ROOT)

For Each objSubKey In objRegRootKey.SubKeys
  StdOut.WriteLine objSubKey.Name
Next

StdOut.WriteLine ""
StdOut.WriteLine "Press ENTER to continue..."
StdIn.ReadLine

--
Michael Harris
Microsoft.MVP.Scripting
--

Please do not email questions - post them to the newsgroup instead.
--

Quote:

> I'm new to programing. I can't seem to get the script below coverted to VBS.
> Can anyone help? I really don't need to access a remote registry. The local
> registry is what I want to work with.

> Thanks for all the help. You guys have been great!
> Lando

> ***********************************************
> Dim WSHShell
>  Set WSHShell = WScript.CreateObject("WScript.Shell")

> Dim objRemoteRegistry

> 'See if we can obtain the Registry of machine Lab1:
> Set objRemoteRegistry = RemoteRegistry("IFORKASH-2K")

> 'Print out all the subkeys of the HKEY_CLASSES_ROOT on the Lab1 machine
> Dim objSubKey As RegKey
> Dim objRegRootKey As regKey

> var ProxyOnOff =
> WshShell.RegRead("HKEY_USERS\\ThisUser\\Software\\Microsoft\\Windows\\Curren
> tVersion\\Internet Settings\\ProxyEnable")

> var ProxyType = typeof(ProxyOnOff)

> Set objRegRootKey = objRemoteRegistry.RegKeyFromHKey(HKEY_CLASSES_ROOT)

> For Each objSubKey In objRegRootKey.SubKeys
> Debug.Print objSubKey.Name
> Next objSubKey
> ************************************************************


> > The good examples are on Clarence's site (http://cwashington.netreach.net)
> which unfortunately is
> > temporarily offline.

> > Check the regobj.doc file that came with the component...  The examples
> are for VB but translate
> > easily to vbscript...

> > --
> > Michael Harris
> > Microsoft.MVP.Scripting
> > --

> > Please do not email questions - post them to the newsgroup instead.
> > --



> > > Hi,
> > > I new to scripting/programming. Can someone post an example VBS script
> that
> > > uses this control? I just need some basics and can work from there. I am
> > > looking to delete registry keys and read registry keys? Also, is there a
> way
> > > to silently register this control? Thanks in advance for the help.

> > > Lando



Tue, 30 Sep 2003 04:26:04 GMT  
 
 [ 5 post ] 

 Relevant Pages 

1. Newbie needs help in reading installed programs from the registry using RegObj.dll

2. Newbie question on Regobj.dll

3. Newbie needs help in reading installed programs from the registry using RegObj.dll

4. Newbie needs help in reading installed programs from the registry using RegObj.dll

5. Newbie needs help in reading installed programs from the registry using RegObj.dll

6. I need documentation on how to use RegObj.dll (registry manip dll)

7. Reading REG_BINARY Keys with RegObj.dll

8. sfImpersonator and RegOBJ.dll

9. regobj.dll

10. regobj.dll

11. RegObj.dll

12. RegObj.dll question

 

 
Powered by phpBB® Forum Software