Advertisement

Lock / shut down PC after certain times?

Started by May 11, 2010 06:48 AM
12 comments, last by Windryder 14 years, 6 months ago
I'm currently suffering a bit from insomnia, which results in me spending more and more time in the evenings behind my computer, because I cannot sleep anyway. The results are predictable: I get to bed even later and still cannot sleep. I want to fix this, but since I lack the discipline here(laying in bed while being unable to sleep for 2 hours is excruciating) to do something about it, I need help. I remember how older Windows 2000 machines allowed users to set account lock out on certain times, but that doesn't seem to work anymore on Windows 7. Does anyone know of any software that force hibernates my machine between certain times? That way I am at least forced to go to bed instead of waste it sitting idle in front of my computer(which is about just the same as laying in bed).

I usually fall asleep listening to something on my pc and use the command line:

at 01:00 shutdown /s

I googled for sleeping a computer and the results seem to be much more complicated than this, though i've not looked at the command line args for shutdown in any detail.
Advertisement
Work out, jog, whatever during the day.
This helped me with my sleeping problems.
I'm pretty sure Windows 7 has parental controls similar to Mac OSX's built in.
On the mac this shuts the computer down at certain times so that children can't use the computer past certain hours. So if the windows one works the same way, then you're in luck.

They've been plugging the feature on the TV for long enough. See if you can find it.
Just use task scheduler in Win7 to create a task to run when you want to go to sleep.

Use something like this as your task command:

shutdown /h /f

or

ping -n 20 127.0.0.1 > NUL 2>&1 & shutdown /h /f

if you want some grace time.
It is I, the spectaculous Don Karnage! My bloodthirsty horde is on an intercept course with you. We will be shooting you and looting you in precisely... Ten minutes. Felicitations!
Quote: Original post by Don Carnage
Just use task scheduler in Win7 to create a task to run when you want to go to sleep.

Use something like this as your task command:

shutdown /h /f

or

ping -n 20 127.0.0.1 > NUL 2>&1 & shutdown /h /f

if you want some grace time.


Or just use the built in shutdown timer...

shutdown -t 60


That'll shut down the computer in 60 seconds and you'll see a timer dialog.
But anyway. Why would anyone want a shutdown to happen? Losing all your hard work if it's forced while you're not there or if you can't react in time. I'd say there must be a better solution.
Advertisement
Quote: Original post by SymLinked
Quote: Original post by Don Carnage
Just use task scheduler in Win7 to create a task to run when you want to go to sleep.

Use something like this as your task command:

shutdown /h /f

or

ping -n 20 127.0.0.1 > NUL 2>&1 & shutdown /h /f

if you want some grace time.


Or just use the built in shutdown timer...

shutdown -t 60


That'll shut down the computer in 60 seconds and you'll see a timer dialog.
But anyway. Why would anyone want a shutdown to happen? Losing all your hard work if it's forced while you're not there or if you can't react in time. I'd say there must be a better solution.


Give it a longer timer, and a warning popup?

"Get to bed in 10 Minutes!"

"I'm shutting off in 5 Minutes!"

"You have 60 Seconds to save your work!"

"If you haven't saved your work, you likely don't have time as I'm shutting down before you have time to finish reading this annoyingly and needlessly long warning message."



If you lose work because you fail to save with something like that, then it is your own fault.
Old Username: Talroth
If your signature on a web forum takes up more space than your average post, then you are doing things wrong.
and you know that after short time, all you do is to cancel the shutdown/prevent the shutdown. if you're lazy, you put a lot of work fighting for your laziness.. which is ridiculous but true.

get to bed, or don't. that form of control most likely will fail anyways.

but just in case, shutdown /? on the command line brings up all options you can use.
If that's not the help you're after then you're going to have to explain the problem better than what you have. - joanusdmentia

My Page davepermen.net | My Music on Bandcamp and on Soundcloud

Quote: Original post by SymLinked
Quote: Original post by Don Carnage
Just use task scheduler in Win7 to create a task to run when you want to go to sleep.

Use something like this as your task command:

shutdown /h /f

or

ping -n 20 127.0.0.1 > NUL 2>&1 & shutdown /h /f

if you want some grace time.


Or just use the built in shutdown timer...

shutdown -t 60


That'll shut down the computer in 60 seconds and you'll see a timer dialog.
But anyway. Why would anyone want a shutdown to happen? Losing all your hard work if it's forced while you're not there or if you can't react in time. I'd say there must be a better solution.


in windows 7 does the shutdown timer insta-shut down or is it the same as hitting the shutdown button? I think 7 holds the shutdown till your programs have a chance to save/you close all the dialogue boxes asking you to save.
Better yet: Don't have a computer, TV, or any other distractions in your bedroom. Bedrooms are for sleeping, not computing or watching TV.

It really does come down to self control. If you can't go to bed on time, who is to say you are capable of other, bigger things that involve self control?

This topic is closed to new replies.

Advertisement