FancyPrairie
Programmer
I'm trying to write a simple script. One of the things I want to do is to get the command line arguments, which I've found the syntax for. However, I don't understand that when I see examples (in this forum and others) the syntax that's used is:
Dim oArgs
Set oArgs = WScript.Arguments
When I use this syntax, I get an error telling my that the WScript object has not been created. I've also seen syntax like this:
set Something = WScript.CreateObject(...)
But the only way I can make it work is like this:
Set Something = CreateObject(...)
I save my files as type .vbs
I don't understand.
Dim oArgs
Set oArgs = WScript.Arguments
When I use this syntax, I get an error telling my that the WScript object has not been created. I've also seen syntax like this:
set Something = WScript.CreateObject(...)
But the only way I can make it work is like this:
Set Something = CreateObject(...)
I save my files as type .vbs
I don't understand.