user24
user24

Reputation: 75

VBScript to open, run and close Tor browser

Please edit this VBScript to open, run and close Tor browser:

Dim objShell
Set objShell = WScript.CreateObject("WScript.Shell")
objShell.Exec("""C:\Users\Name\Desktop\Tor\Tor Browser\Browser\Tor.exe""/http://www.google.com")
Set objShell = Nothing
WScript.Sleep 20000
Set objShell = objshell.Exec("taskkill /fi ""imagename eq Tor.exe""")

It opens and runs, but doesn't close.

Upvotes: 1

Views: 266

Answers (1)

Hackoo
Hackoo

Reputation: 18857

You should try something like this :

Dim objShell
Set objShell = CreateObject("WScript.Shell")
objShell.Run "Taskkill /F /IM Tor.exe",0,True

Upvotes: 3

Related Questions