Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations sizbut on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Parameters 1

Status
Not open for further replies.

evilkalah

Technical User
Jul 30, 2003
11
BE
Can i give a parameter to a vbscript in windows and how can i call them up? for example like in dos

format c:
so i can use th c: as parameter and in with varnaam it is in
 
Calling:
Code:
Wscript YourScript.vbs Arg1 Arg2 ... ArgN
or in console mode
Code:
Cscript YourScript.vbs Arg1 Arg2 ... ArgN
In your script:
Code:
Set objArgs = WScript.Arguments
For I = 0 to objArgs.Count - 1
   WScript.Echo objArgs(I)
Next

Hope This Help
PH.
 
maybe it isn't clear

start.vbs varstart=yes


or something else
that i wanne know how it works and how to read the value of it in the code
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top