creating a scheduled task to restart an existing service in SERVICES.MSC

Hi,

  I have a service called "workflow" in services.msc (on Windows 2008 Std) that becomes ineffective from time to time, so I end up restarting it once a week on average when the user calls me.
 Can I create a DOS command script, store in .BAT file and have it run once a day so that I don't have to open SERVICES.MSC and re-start every time the user calls me with the problem.

Path to Executable:
C:\Program Files\Software Systems, Inc\DirectoryName\Workflow.exe
Logon as "Local System Account"

Thanks.
LVL 1
sgleeAsked:
Who is Participating?
 
xDUCKxCommented:
net stop workflow
net start workflow

Open in new window


or

taskkill /F /IM workflow.exe
C:\Program Files\Software Systems, Inc\DirectoryName\Workflow.exe

Open in new window


Top one will use the services.msc snap in to stop/start cleanly

Bottom one will forcefully kill the process and start it again.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.