in reply to Re^2: Automatic Windows Reboot using Perl
in thread Automatic Windows Reboot using Perl

Although I agree with the other posters in that if all you want is to reboot the computer you should just use shutdown.exe, if you need a Perl solution (say for the end of a Perl script in which you desire a reboot), this is what I use:

Win32::InitiateSystemShutdown( '', "\nAction Complete.\n\nSystem will now Reboot\!", 20, 0, 1 );

- - arden.

Replies are listed 'Best First'.
Re^4: Automatic Windows Reboot using Perl
by Anonymous Monk on Jul 01, 2004 at 14:59 UTC
    This is exactly what I am looking for! Thanks!
    As mentionedby others, "run shutdown.exe", I was unable to find shutdown.exe on any WIN2K box that I have encountered.
    So.... the Win32::InitiateSystemShutdown routine works perfectly!