Core Function Shutdown
From Sputnik Wiki
Shutdown( <shutdown code> )
Contents |
Description
Shuts down the system.
Parameters
shutdown code
The shutdown code is a combination of the following values:
0 = Logoff 1 = Shutdown 2 = Reboot 4 = Force 8 = Power down 32= Suspend 64= Hibernate
Add the required values together. To shutdown and power down, for example, the code would be 9 (shutdown + power down = 1 + 8 = 9).
Standby or hibernate are ignored if other codes are set. They are also ignored under Win9x.
Return Value
Success: Returns 1.
Failure: Returns 0.
Remarks
A environment variable set in this way will only be accessible to programs that Sputnik spawns (Run, RunWait).
Once Sputnik closes, the variables will cease to exist.
Example
Shutdown(6); // Force a reboot