On Windows XP, the following command in a script will prevent any power saving options from being enabled on the PC (monitor sleep, HD sleep, etc.). This is useful for kiosk applications.
powercfg.exe /setactive presentation
What is the equivalent on Vista?
Setting a value to never can be done by passing a value of 0
to the -change
option, i.e.:
powercfg.exe -change -monitor-timeout-ac 0
means the monitor timeout will be set to "Never". So the presentation plan can be achieved via:
powercfg.exe -change -monitor-timeout-ac 0
powercfg.exe -change -disk-timeout-ac 0
powercfg.exe -change -standby-timeout-ac 0
powercfg.exe -change -hibernate-timeout-ac 0