Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

272 lines
20 KiB

//Microsoft Developer Studio generated resource script.
//
#include <windows.h>
#include "resource.h"
#include "cmdlineres.h"
#include "cmdline.rc"
/////////////////////////////////////////////////////////////////////////////
//
// String Table
//
STRINGTABLE DISCARDABLE
BEGIN
IDS_ON "ON"
IDS_OFF "OFF"
IDS_HIBER_INVALID_STATE "Hibernation state must be ""on"" or ""off""\n"
IDS_GLOBAL_FLAG_INVALID_STATE "Global Flag state must be ""on"" or ""off""\n"
IDS_GLOBAL_FLAG_INVALID_FLAG "Global Flag must be one of ""BATTERYICON"", ""MULTIBATTERY"",""RESUMEPASSWORD"", ""WAKEONRING"", ""VIDEODIM""\n"
IDS_HIBER_UNSUPPORTED "System does not support hibernation\n"
IDS_HIBER_CONFIG_FAIL "Unable to configure hibernation file\n"
IDS_SYSCAP_FAIL "Unable to determine system capabilities\n"
IDS_INVALID_CMDLINE_PARAM "Invalid Parameters -- try ""/?"" for help\n"
IDS_OUT_OF_MEMORY "Out of Memory\n"
IDS_SCHEME_NOT_FOUND "Scheme Not Found\n"
IDS_ACTIVE_SCHEME_INVALID "Active Power Scheme is Invalid\n"
IDS_SCHEME_ALREADY_EXISTS "A scheme with that name already exists\n"
IDS_SCHEME_CREATE_FAIL "Unable to create a new power scheme\n"
IDS_INVALID_NUMERICAL_IMPORT "A scheme name must be specified when creating a new scheme.\nEither specify an existing scheme number or do not use /NUMERICAL.\n"
END
STRINGTABLE DISCARDABLE
BEGIN
IDS_SCHEME_NAME "Name %s\n"
IDS_SCHEME_DESCRIPTION "Description %s\n" // unused
IDS_MONITOR_TIMEOUT_AC "Turn off monitor (AC) "
IDS_MONITOR_TIMEOUT_DC "Turn off monitor (DC) "
IDS_DISK_TIMEOUT_AC "Turn off hard disks (AC) "
IDS_DISK_TIMEOUT_DC "Turn off hard disks (DC) "
IDS_STANDBY_TIMEOUT_AC "System standby (AC) "
IDS_STANDBY_TIMEOUT_DC "System standby (DC) "
IDS_HIBER_TIMEOUT_AC "System hibernates (AC) "
IDS_HIBER_TIMEOUT_DC "System hibernates (DC) "
END
STRINGTABLE DISCARDABLE
BEGIN
IDS_USAGE_START "\n"
IDS_USAGE_01 "POWERCFG [/LIST | /QUERY [name] | /CREATE name | /DELETE name |\n"
IDS_USAGE_02 " /SETACTIVE name | /CHANGE name settings |\n"
IDS_USAGE_03 " /HIBERNATE {ON|OFF} | /EXPORT name [/FILE filename] |\n"
IDS_USAGE_04 " /IMPORT name [/FILE filename] | /GLOBALPOWERFLAG {ON|OFF} /OPTION flag |\n"
IDS_USAGE_04_1 " /BATTERYALARM {LOW|CRITICAL} [settings] | /?]\n"
IDS_USAGE_05 "\n"
IDS_USAGE_06 "Description:\n"
IDS_USAGE_07 " This command line tool enables an administrator to control\n"
IDS_USAGE_08 " the power settings on a system.\n"
IDS_USAGE_09 "\n"
IDS_USAGE_10 "Parameter List:\n"
IDS_USAGE_11 " /LIST, /L Lists the names of existing power schemes.\n"
IDS_USAGE_12 " /QUERY, /Q Displays the configuration of the specified power scheme.\n"
IDS_USAGE_13 " If no name is specified, the configuration of the currently\n"
IDS_USAGE_14 " active power scheme is displayed.\n"
IDS_USAGE_15 " /CREATE, /C Creates a power scheme with the specified name. The new\n"
IDS_USAGE_16 " scheme is created with the properties of the currently\n"
IDS_USAGE_17 " active scheme.\n"
IDS_USAGE_18 " /DELETE, /D Deletes the power scheme with the specified name.\n"
IDS_USAGE_19 " /SETACTIVE, /S Makes the power scheme with the specified name active.\n"
IDS_USAGE_20 " /CHANGE, /X Changes settings of the specified power scheme. Additional\n"
IDS_USAGE_21 " switches specify the changes as follows:\n"
IDS_USAGE_22 " /monitor-timeout-ac <minutes>\n"
IDS_USAGE_23 " /monitor-timeout-dc <minutes>\n"
IDS_USAGE_24 " /disk-timeout-ac <minutes>\n"
IDS_USAGE_25 " /disk-timeout-dc <minutes>\n"
IDS_USAGE_26 " /standby-timeout-ac <minutes>\n"
IDS_USAGE_27 " /standby-timeout-dc <minutes>\n"
IDS_USAGE_28 " /hibernate-timeout-ac <minutes>\n"
IDS_USAGE_29 " /hibernate-timeout-dc <minutes>\n"
IDS_USAGE_30 " /processor-throttle-ac <throttle>\n"
IDS_USAGE_31 " /processor-throttle-dc <throttle>\n"
IDS_USAGE_32 " AC settings are used when the system is on AC power.\n"
IDS_USAGE_33 " DC settings are used when the system is on battery power.\n"
IDS_USAGE_34 " Setting a timeout to zero will disable the corresponding\n"
IDS_USAGE_35 " timeout feature. Supported throttle settings are NONE\n"
IDS_USAGE_36 " CONSTANT, DEGRADE, and ADAPTIVE.\n"
IDS_USAGE_37 " /EXPORT, /E Exports the power scheme with the specified name to a\n"
IDS_USAGE_38 " file. If no filename is specified, the default is \n"
IDS_USAGE_39 " SCHEME.POW. This additional parameter is supported:\n"
IDS_USAGE_40 " /FILE <filename>\n"
IDS_USAGE_41 " /IMPORT, /I Imports the power scheme from a file under the specified\n"
IDS_USAGE_42 " name. If no filename is specified, the default is\n"
IDS_USAGE_43 " SCHEME.POW. If a scheme with that name already exists, it\n"
IDS_USAGE_44 " is replaced with the new one. This additional parameter\n"
IDS_USAGE_45 " is supported:\n"
IDS_USAGE_46 " /FILE <filename>\n"
IDS_USAGE_47 " /HIBERNATE, /H Turns the hibernation feature on/off. Hibernation timeout\n"
IDS_USAGE_48 " is not supported on all systems that support hibernation\n"
IDS_USAGE_49 " /NUMERICAL, /N Allows the power scheme to be operated upon to be specified\n"
IDS_USAGE_50 " using a numerical identifier. When using this switch, in\n"
IDS_USAGE_51 " place of the name of the power scheme on the command line,\n"
IDS_USAGE_52 " specify its numerical identifier. This switch may be used\n"
IDS_USAGE_53 " in combination with the /QUERY, /DELETE, /SETACTIVE,\n"
IDS_USAGE_54 " /CHANGE, /EXPORT, and /IMPORT commands.\n"
IDS_USAGE_55 " /GLOBALPOWERFLAG, /G {ON|OFF} Turns one of the global power flags on/off.\n Valid flags (to be used after ""/OPTION "") are:\n"
IDS_USAGE_56 " BATTERYICON: Turns the battery meter icon in the\n system tray on/off.\n"
IDS_USAGE_57 " MULTIBATTERY: Turns on/off multiple battery display\n in system Power Meter.\n"
IDS_USAGE_58 " RESUMEPASSWORD: Prompt for password on resuming the\n system.\n"
IDS_USAGE_59 " WAKEONRING: Turn on/off wake on ring support.\n"
IDS_USAGE_60 " VIDEODIM: Turn on/off support for dimming video\n display on battery power.\n"
IDS_USAGE_60_01 " /AVAILABLESLEEPSTATES, /A Reports the sleep states available on the\n system. Attempts to report reasons why sleep states are\n unavailable.\n"
IDS_USAGE_60_02 " /BATTERYALARM, /B {LOW|CRITICAL} Displays or configures the specified\n battery alarm. Using this option without any switches will\n display the current settings.\n The following switches can be specified:\n"
IDS_USAGE_60_03 " /activate <on|off>\n Enables or disables the alarm.\n"
IDS_USAGE_60_04 " /level <percentage (0 - 100)>\n The alarm will be activated when the power level\n reaches this percentage.\n"
IDS_USAGE_60_05 " /text <on|off>\n Turns the text notification on or off.\n"
IDS_USAGE_60_06 " /sound <on|off>\n Turns the audible notification on or off.\n"
IDS_USAGE_60_07 " /action <none|shutdown|hibernate|standby>\n Specifies the action to take when this alarm goes\n off. Not all actions are always available.\n"
IDS_USAGE_60_08 " /forceaction <on|off>\n Force stand by or shutdown even if a program stops\n responding.\n"
IDS_USAGE_60_09 " /program <on|off>\n Specifies whether the system will run a program\n when the alarm goes off. When this option is used,\n the output will be the taskname that can be used\n with schtasks.exe /change to configure the program.\n"
IDS_USAGE_61 " /HELP, /? Displays information on command-line parameters.\n"
IDS_USAGE_62 "\n"
IDS_USAGE_63 "Examples:\n"
IDS_USAGE_64 " POWERCFG /LIST\n"
IDS_USAGE_65 " POWERCFG /QUERY scheme\n"
IDS_USAGE_66 " POWERCFG /QUERY\n"
IDS_USAGE_67 " POWERCFG /CREATE scheme\n"
IDS_USAGE_68 " POWERCFG /DELETE scheme\n"
IDS_USAGE_69 " POWERCFG /SETACTIVE scheme\n"
IDS_USAGE_70 " POWERCFG /CHANGE scheme /monitor-timeout-dc 15\n"
IDS_USAGE_71 " POWERCFG /CHANGE scheme /monitor-timeout-dc 0\n"
IDS_USAGE_72 " POWERCFG /HIBERNATE on\n"
IDS_USAGE_73 " POWERCFG /EXPORT scheme /file file\n"
IDS_USAGE_74 " POWERCFG /QUERY number /NUMERICAL\n"
IDS_USAGE_75 " POWERCFG /GLOBALPOWERFLAG on /OPTION BATTERYICON\n"
IDS_USAGE_76 " POWERCFG /AVAILABLESLEEPSTATES\n"
IDS_USAGE_77 " POWERCFG /BATTERYALARM low\n"
IDS_USAGE_78 " POWERCFG /BATTERYALARM critical /ACTIVATE on /LEVEL 6 /ACTION hibernate\n"
IDS_USAGE_END "\n"
END
STRINGTABLE DISCARDABLE
BEGIN
IDS_LIST_HEADER1 "\nExisting Power Schemes\n"
IDS_LIST_HEADER2 "----------------------\n"
IDS_QUERY_HEADER1 "\nField Description Value\n"
IDS_QUERY_HEADER2 "----------------- -----\n"
IDS_QUERY_FOOTER "\nNote that a timeout value of zero represents a disabled timeout feature.\n" // unused
IDS_UNEXPECTED_ERROR "An unexpected error condition has occurred. Unable to perform operation. You may not have permission to perform this operation.\n"
IDS_HIBER_OUT_OF_RANGE "The hibernation timeout must be at least as long as the standby timeout.\n"
IDS_MINUTES "After %lu mins\n"
IDS_DISABLED "Never\n"
IDS_UNSUPPORTED "Not Supported\n"
IDS_STANDBY_WARNING "WARNING: System does not support standby\n"
IDS_HIBER_WARNING "WARNING: System may not support waking from standby in order to hibernate\n"
IDS_MONITOR_WARNING "WARNING: System does not support monitor power saving\n"
IDS_DISK_WARNING "WARNING: System does not support disk power saving\n"
IDS_HIBER_PRIVILEGE "No permission to enable/disable hibernation file\n"
IDS_DEFAULT_FILENAME "SCHEME.POW"
IDS_THROTTLE_AC "Processor Throttle (AC) "
IDS_THROTTLE_DC "Processor Throttle (DC) "
IDS_THROTTLE_NONE "NONE\n"
IDS_THROTTLE_CONSTANT "CONSTANT\n"
IDS_THROTTLE_DEGRADE "DEGRADE\n"
IDS_THROTTLE_ADAPTIVE "ADAPTIVE\n"
IDS_THROTTLE_UNKNOWN "UNKNOWN\n"
IDS_DLL_LOAD_ERROR "Unable to load POWRPROF.DLL\n"
IDS_DLL_PROC_ERROR "Unable to use POWRPROF.DLL\n"
IDS_SCHEME_ID "Numerical ID %u\n"
END
STRINGTABLE DISCARDABLE
BEGIN
IDS_HIBER_FAILED_DESCRIPTION_HEADER "Hibernation failed with the following error: %s\nThe following items are preventing hibernation on this system.\n"
IDS_HIBER_REASON_NONE "\tThere are no reported reasons hibernation does not work. Ensure that you have permission to enable hibernation on this system.\n"
IDS_HIBER_REASON_NOBIOS "\tThe system does not support hibernation.\n"
IDS_HIBER_REASON_BIOSINCOMPAT "\tThe system firmware support hibernation, but it does not work properly.\n"
IDS_HIBER_REASON_NOOSPM "\tThe system doesn't support hibernation.\n"
IDS_HIBER_REASON_LEGDRV "\tThere are one or more legacy drivers installed: %s\n"
IDS_HIBER_REASON_HIBERSTACK "\tThe storage drivers do not support hibernation.\n"
IDS_HIBER_REASON_HIBERFILE "\tThe system could not create the hibernation file. The specific error code is 0x%x.\n"
IDS_HIBER_REASON_POINTERAL "\tAn internal error occurred. The specific error code is 0x%x.\n"
IDS_HIBER_REASON_PAEMODE "\tThe system is running in PAE mode, and hibernation is not allowed in PAE mode.\n"
IDS_HIBER_REASON_MPOVERRIDE "\tThe system has more than one processor and hibernate will not work properly because of this.\n"
IDS_HIBER_REASON_DRIVERDOWNGRADE "\tThe VGAPNP.SYS driver specifically disallows hibernation. Check for a more appropriate video driver to enable hibernation.\n"
IDS_HIBER_REASON_UNKNOWN "\tAn unknown error occurred while enabling hibernation.\n"
IDS_SX_REASON_NONE "\tThere are no reported reasons for the sleep state to not work.\n"
IDS_SX_REASON_NOBIOS "\tThe system firmware does not support this standby state.\n"
IDS_SX_REASON_BIOSINCOMPAT "\tThe system firmware support this standby state, but it does not work properly.\n"
IDS_SX_REASON_NOOSPM "\tThe standby state is not supported on this system. ACPI is not enabled or not supported on this system.\n"
IDS_SX_REASON_LEGDRV "\tThere are one or more legacy drivers installed which prevent this standby state: %s\n"
IDS_SX_REASON_HIBERSTACK "\tSHOULD NOT OCCUR.\n"
IDS_SX_REASON_HIBERFILE "\tSHOULD NOT OCCUR.\n"
IDS_SX_REASON_POINTERAL "\tSHOULD NOT OCCUR.\n"
IDS_SX_REASON_PAEMODE "\tThe system is running in PAE mode, and this standby state is not allowed in PAE mode.\n"
IDS_SX_REASON_MPOVERRIDE "\tThe system has more than one processor and this standby state will not work properly because of this.\n"
IDS_SX_REASON_DRIVERDOWNGRADE "\tThe VGAPNP.SYS display driver does not support standby. Please consult your hardware vendor for an updated display driver.\n"
IDS_SX_REASON_UNKNOWN "\tAn unknown error occurred while enabling hibernation.\n"
IDS_SX_REASON_NOOSPM_IA64 "\tThe system doesn't support this standby state.\n"
IDS_HIBER_REASON_NOOSPM_IA64 "\tThe system doesn't support hibernation.\n"
IDS_BASE_S1_HEADER "Standby (S1)"
IDS_BASE_S2_HEADER "Standby (S2)"
IDS_BASE_S3_HEADER "Standby (S3)"
IDS_CANTGETSLEEPSTATES "Unable to retreive the supported sleep states on the system."
IDS_CANTGETSSTATEREASONS "Unable to retreive verbose reasons why sleep states are unavailabe on this system."
IDS_SLEEPSTATES_AVAILABLE "The following sleep states are available on this system:"
IDS_SLEEPSTATES_UNAVAILABLE "The following sleep states are not available on this system:"
IDS_STANDBY "Standby"
IDS_LEFTPAREN "("
IDS_S1 "S1"
IDS_S2 "S2"
IDS_S3 "S3"
IDS_RIGHTPAREN ")"
IDS_HIBERNATE "Hibernate"
IDS_SHUTDOWN "Shutdown"
END
STRINGTABLE DISCARDABLE
BEGIN
IDS_ALARM_HEADER1 "\nBattery Alarm Setting Value\n"
IDS_ALARM_HEADER2 "----------------------- -----\n"
IDS_ALARM_NAME "Alarm %s\n"
IDS_LOW "Low"
IDS_CRITICAL "Critical"
IDS_ALARM_ACTIVE "Activate %s\n"
IDS_ALARM_LEVEL "Level %d%%\n"
IDS_ALARM_TEXT "Text Notification %s\n"
IDS_ALARM_SOUND "Sound notification %s\n"
IDS_ALARM_ACTION "Action %s\n"
IDS_NONE "None"
IDS_INVALID "Invalid action!!!!"
IDS_ALARM_FORCE " Force action %s\n"
IDS_ALARM_PROGRAM "Run a program %s\n"
IDS_ALARM_PROGRAM_NAME " Program %s\n"
IDS_ALARM_INVALID_ALARM "Alarm must be ""Low"" or ""Critical"".\n"
IDS_ALARM_INVALID_ACTIVATE "/ACTIVATE must be followed by ""on"" or ""off"".\n"
IDS_ALARM_INVALID_LEVEL "/LEVEL must be followed by a number from 0 to 100\n"
IDS_ALARM_INVALID_TEXT "/TEXT must be followed by ""on"" or ""off"".\n"
IDS_ALARM_INVALID_SOUND "/SOUND must be followed by ""on"" or ""off"".\n"
IDS_ALARM_INVALID_ACTION "/ACTION must be followed by ""none"", ""standby"", ""hibernate"", or ""shutdown"".\n"
IDS_ALARM_INVALID_FORCE "/FORCEACTION must be followed by ""on"" or ""off"".\n"
IDS_ALARM_INVALID_PROGRAM "/PROGRAM must be followed by ""on"" or ""off"".\n"
IDS_ALARM_PROGRAM_FAILED "WARNING: Initialization of task ""%s"" failed.\nThis task must be created manually with flags set to allow the task to run\nwhile the system is running on batteries.\n"
IDS_ALARM_STANDBY_UNSUPPORTED "This system does not support standby.\n"
IDS_ALARM_HIBERNATE_DISABLED "Hibernation is not enabled. Use: ""POWERCFG /HIBERNATE on""\n"
IDS_HIBERNATE_ALARM_DISABLED "WARNING: Battery alarm action changed from HIBERNATE to NONE.\n"
IDS_HIBERNATE_ALARM_DISABLE_FAILED "WARNING: Failed to automatically change battery alarm action from HIBERNATE.\n"
IDS_ALARM_LEVEL_MINIMUM "WARNING: Level set to %d%%. This is the minimum alarm level for this system.\n"
IDS_ALARM_LEVEL_EQUAL "WARNING: the low battery alarm cannot be set to a lower level than the critical battery alarm. Both alarms have been set to %d%%.\n"
IDS_ALARM_FORCE_CRITICAL "WARNING: The critical battery alarm must be set to force stand by or hibernation.\n"
END
/////////////////////////////////////////////////////////////////////////////
//
// Version
//
//
// Version resources
//
#include <ntverp.h>
#define VER_FILETYPE VFT_APP
#define VER_FILESUBTYPE VFT2_UNKNOWN
#define VER_FILEDESCRIPTION_STR "Power Settings Command-Line Tool"
#define VER_INTERNALNAME_STR "PowerCfg.exe"
#define VER_ORIGINALFILENAME_STR "PowerCfg.exe"
#include <common.ver>