blob: 6a178410557212a33881d3bc83ad561074bc8d62 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
set argIn = WScript.Arguments
num = argIn.Count
if num = 0 then
WScript.Echo "Call a Windows batch file (*.cmd, *.bat) without showing the console window" & VbCrLf & VbCrLf &_
"Command line:" & VbCrLf & "WScript HideConsole.vbs MyBatchfile.cmd <command line arguments>"
WScript.Quit 1
end if
argOut = ""
for i = 0 to num - 1
argOut = argOut & """" & argIn.Item(i) & """ "
next
set WshShell = WScript.CreateObject("WScript.Shell")
WshShell.Run argOut, 0, True
|