How can i have a bat file which opens an application lets call it firefox.exe.how would i call the bat file or any other script ie vbs to minimize the application ie firefox.exe then after lets say a minute or two close it.please mind you the start\min
does not work?below is an example /part of my script?please help out?
"C:\Program Files\Mozilla Firefox\firefox.exe" -tray
/min - switch to run minimized.
Type taskkill /IM your-program-name. your-program-extension /T /F and then hit ↵ Enter . Repeat this command for as many programs as you want! When finished, type exit on the last line and hit ↵ Enter .
Switch to the Command Prompt window that you want to minimize, and right-click the minimize button. What is this? This will send the window to the system tray. You will see an EXE icon in the system tray to indicate that it is running.
Try:
start /min "" firefox
.. or (if FireFox is your default browser):
start /min "" "http://google.com"
Have you tried:
start /min C:\Program Files\Mozilla Firefox\firefox.exe
using the forward slash?
The proper parameter would be -turbo
, but it is long obsolete and probably not functional.
start "path\firefox.exe http://example.com/file.html" /MIN
might work better.
EDIT: Oops, it has already been suggested.
here is how i solved the problem using a command line tool known as nircmd,i used the hide parameter to hide the firefox and it acctully works perfectly.see the code example.
START "" "C:\Program Files\Mozilla Firefox\firefox.exe" -P "america" -no-remote http://hakikahost.com error.html
"nircmd.exe" win hide process "firefox.exe"
the link to nircmd ...link
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With