Is it possible to have sabnzbd run a script without opening the cmd window? That steals focus from my game if i am playing at the time. I checked out this program to see if it would help, but of course, when you run a cmd file to execute this script, it of course opens a cmd window lol.
http://www.ntwind.com/software/utilities/hstart.html
any ideas?
modify script to not display cmd window?
Re: modify script to not display cmd window?
This is untested, but try:
Change the path in the last line, and save the text as a .vbs file in your scripts folder.
Code: Select all
Const HIDDEN_WINDOW = 12
strComputer = "."
Set objWMIService = GetObject("winmgmts:" _
& "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")
Set objStartup = objWMIService.Get("Win32_ProcessStartup")
Set objConfig = objStartup.SpawnInstance_
objConfig.ShowWindow = HIDDEN_WINDOW
Set objProcess = GetObject("winmgmts:root\cimv2:Win32_Process")
errReturn = objProcess.Create("[b]C:\path\to\script.bat[/b]", null, objConfig, intProcessID)