Vbs Exec Hidden

[Solved] Vbs Exec Hidden | Vb - Code Explorer | yomemimo.com
Question : vbs exec hidden

Answered by : httpsgithubcomgarzj

Set oShell = CreateObject("WScript.Shell")
' If running under wscript.exe, relaunch under cscript.exe in a hidden window
If InStr(1, WScript.FullName, "wscript.exe", vbTextCompare) > 0 Then cmd = "cscript.exe """ & WScript.ScriptFullName & """" oShell.Run cmd, 0, False WScript.Quit
End If
' We can now read the output from an Exec in the background
strOutput = CreateObject("WScript.Shell").Exec("tasklist.exe").StdOut.ReadAll()
MsgBox strOutput

Source : | Last Update : Sun, 16 Aug 20

Answers related to vbs exec hidden

Code Explorer Popular Question For Vb