Sign in to follow this  
Followers 0
JayJay

Shutdown(x) not working

3 posts in this topic

I'm new here. Haven't done a lot of programming for a long time, but I'm trying to "get the hang of it" again.

I made a script to shutdown the computer at a specified time.

Although the script works on this computer (the one I'm typing on now), it does not work on the computer it is intended for. :D

On that computer, the screen goes black, the mousepointer stays visible and that is it. No logout, no shutdown, nothing. No keyboeard response either, I have to push the reset-button to get it working again.

There is a program available on the forum to shutdown a computer, which does work on my other computer.

So instead of Shutdown(5) (force shutdown) that I used, I changed it to Shutdown(9) (shutdown/powerdown) that the other program is using, but it still does not work on that computer.

Any ideas why it isn't working on the Athlon 2400+?

Share this post


Link to post
Share on other sites



im guessing the computer works with regular shutting down? because sometimes i just shutdown my comp and go to bed the screen goes black but the mouse is visible and can be, never figured out what it was.

Share this post


Link to post
Share on other sites

I've made some very easy scripts to shutdown a computer, but IMHO the behavor of the old computer is weird.

This works on both computers:

; Test Script 1

Shutdown(5)

This works only on one of them:

; Test Script 2

While 1

If @HOUR=22 AND @MIN=0 Then Shutdown(5)

WEnd

In order to get it to work on the other computer as well, I had to rewrite it to:

; Test Script 3

While 1

If @HOUR=22 AND @MIN=0 Then ExitLoop

WEnd

Shutdown(5)

(I also tried it with a Sleep(xx) in the loop but that didn't work either)

After that I have re-written the original script to exit the main-loop before the Shutdown().

It now works on both my computers. :D

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0