Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm using Windows Server 2008 R2.

I've created a .NET console application and deployed it to the server. If I double click the .exe application, it runs well and does it's job.

This application has to update values on a database. I need to be able to run this every hour automatically.

How can I achieve this?

share|improve this question
    
Look at the acepted answer here: stackoverflow.com/questions/3243348/… This includes also the option to run it programmatically in .net –  Mr.T Jul 4 '12 at 15:42

3 Answers 3

up vote 4 down vote accepted

The windows task scheduler allows you to regularly run a program. It's in the control panel under administrative tools, or in server manager under configuration.

Just click create task, add a trigger for "On a schedule" and in advanced settings choose "Repeat task every 1 hour for a duration of Indefinitely"

Under actions, add one for start a program and specify your program and any needed arguments

On the first tab, you will probably want to choose "Run whether user is logged on or not" and choose a user to run it as.

share|improve this answer

You should use Windows Task Scheduler for that. You can check this tutorial to get started.

share|improve this answer

Use Task Scheduler. It's pretty straightforward.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.