I could imagine such a thing being able to be done on mac, probably with applescript or something. But windows is something else. Controlling shutdown via a program might be seen as a virus type of activity.

Interesting idea.

Just my half a cents worth.