Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Is there a free or relatively cheap task scheduler system that can react to things like screen resolution changes, file modifications. etc, and spawn tasks executing my own programs?

For instance, if I want to unzip a file when it appears in a directory?

It seems the built-in task scheduler in Windows only comes as close as spawning the program on a time-based schedule.

What alternatives do I have?

share|improve this question
add comment

2 Answers

up vote 1 down vote accepted

I don't know of any pre-built programs. Seeing as you are a developer, you can use FileSystemWatcher in the .NET framework. I've used it to monitor drop boxes in the past. Any time a file-added event fires you can then invoke whatever program you desire via the command line.

As far as resolution changes, I recommend you checkout the win32 API. Seeing as windows is not open source, that's your only bet there. If the event can be hooked into you can create a service to listen for it and run when it fires.

Otherwise, you can create a program where users can change the resolution through your program. This is possible with C# and platform invoke. That way you handle the resolution changed event and do whatever else you desire on top.

share|improve this answer
add comment

You could use Task Scheduler to run a batch script every x minutes, which checks for changes to files and uses the WMIC utility to check screen resolution changes. The current states can be saved to a text file which the script checks against.

AutoIt v3 and AutoHotKey are other avenues which you could explore, which are certainly powerful enough to do what you want to do, but they would require learning new languages. AutoHotKey is probably a bit easier, while AutoIt v3 is more powerful. AutoHotKey is based on the earlier AutoIt v2 syntax.

share|improve this answer
add comment

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.