Passing a parameter to a remote script 
Author Message
 Passing a parameter to a remote script

I have a situation where I need to invoke a remote script with a, for lack
of a better term, "Command Line" parameter (even though there is no command
line).

Is this possible? Do I put the parameter after the script name in the
CreateScript?

I appreciate any assistance.

Pier



Mon, 26 Apr 2004 03:15:19 GMT  
 Passing a parameter to a remote script
The 1st argument (Commandline) of WshController.CreateScript follows the same rules as the 1st argument of WshShell.Run...

Commandline
Required. String value indicating the script's path and switches as they would be typed at the command prompt. The path to the script should appear as seen from the controller computer system rather than the computer system on which you want to run the script.

set obj = WshController.CreateScript(_
    """c:\path with spaces\myscript.vbs"" arg1 ""arg 2"" arg3"_
    ,"servername")

--
Michael Harris
Microsoft.MVP.Scripting
--

Quote:

> I have a situation where I need to invoke a remote script with a, for lack
> of a better term, "Command Line" parameter (even though there is no command
> line).

> Is this possible? Do I put the parameter after the script name in the
> CreateScript?

> I appreciate any assistance.

> Pier



Mon, 26 Apr 2004 03:31:36 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. questions on passing text parameter from server script to client script (some new findings)

2. questions on passing parameter from server script to client script

3. Remote Scripting parameters

4. Passing parameter to vb script

5. how to pass a array parameter from my script in asp

6. Passing parameters from script to command line

7. Passing parameters to a script procedure or function

8. Passing parameters to the script

9. Passing parameters to a batch file from a vb script

10. Passing arrays to remote scripting methods

11. Passing arrays to Remote scripting methods

12. Passing information in remote scripting

 

 
Powered by phpBB® Forum Software