Go Back   Computer Forums > General Computing > Programming
Join Computer forums Today

Thread Tools Search this Thread Display Modes
Old 10-20-2015, 12:32 AM   #1
Solid State Member
Join Date: Sep 2015
Location: america
Posts: 9
Default I need a bat file to close programs at startup

I need a bat file that closes something running in task manager such as chrome.exe 5 min after start up.

d9esco is offline   Reply With Quote
Old 10-20-2015, 04:34 AM   #2
Fully Optimized
BikerEcho's Avatar
Join Date: Feb 2011
Location: Denmark
Posts: 3,888
Default Re: I need a bat file to close programs at startup

if not "%minimized%"=="" goto :minimized
set minimized=true
start /min cmd /C "%~dpnx0"
goto :EOF

ping localhost -n 300 > nul

taskkill ProgramTaskNameHere.exe
Save as SomeName.bat and put it into your startup folder. That will make it start up automatically when the computer logs in.

Is this working out for ya?

The ping localhost 300 command it for the batch file to wait 300 seconds (5 minutes)
and all the above code is for the command prompt to minimize automatically.
If you don't want it to do that, remove it.
MOBO: Asus Maximus 6 Hero - GPU: Gigabyte GTX 980ti xtreme - CPU: I7-4770K - PSU: Corsair AX760
RAM: Corsair Vantage 2x4GB - SSD: Samsung 840 Evo 512GB - Case: NZXT H440
BikerEcho is online now   Reply With Quote

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

All times are GMT -5. The time now is 05:16 PM.

Powered by vBulletin® Version 3.8.8 Beta 4
Copyright ©2000 - 2016, vBulletin Solutions, Inc.
Search Engine Friendly URLs by vBSEO 3.6.0