Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re: Local Reboot of NT Workstation

by $code or die (Deacon)
on Oct 28, 2000 at 18:17 UTC ( #38918=note: print w/replies, xml ) Need Help??


in reply to Local Reboot of NT Workstation

It's in the Win32 Module as well, so this should do the trick:
use Win32; my $machine = ""; my $message = 'WARNING: This system is about to reboot'; my $timeout = 10; # 10 seconds countdown my $forceclose = 1; # Force all applications to close without saving my $reboot = 1; # Reboot the system after shutdown Win32::InitiateSystemShutdown($machine,$message,$timeout,$forceclose,$ +reboot);
There is also an abort call - Win32::AbortSystemShutdown($machine);

Good Luck

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://38918]
help
Chatterbox?
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others pondering the Monastery: (6)
As of 2017-12-17 18:20 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    What programming language do you hate the most?




















    Results (466 votes). Check out past polls.

    Notices?