March 29, 2011 at 9:37 am
I have written a small vb script in Script Task. The script is as below
Dim a As Object
Dim name As String
Dim b As String
name = "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\ComputerName\ActiveComputerName\ComputerName"
a = CreateObject("wscript.shell")
b = a.RegRead(name)
MsgBox(b).ToString()
In this script I am not understanding what exactly "CreateObject("wscript.shell")" is doing..?
Your help is appreciated.
Thanks
S
March 29, 2011 at 9:48 am
how did you write it if you don't know what it does?
it looks like it is creating an instance of wshell
March 29, 2011 at 10:06 am
I just started learning VB. this example is from book "Microsoft VB step by step".
March 29, 2011 at 10:07 am
steveb: Thanks for your help
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply