Partager via


Win32_ComputerShutdownEvent class

The Win32_ComputerShutdownEvent is a Windows Management Instrumentation (WMI) event class that represents events when a computer begins the process of shutting down. It identifies the type of shutdown, which can be a user log off, complete shutdown, or restart.

The following syntax is simplified from Managed Object Format (MOF) code and includes all of the inherited properties. Properties are listed in alphabetic order, not MOF order.

Syntax

[UUID("{A6B834B1-F974-4445-8F2E-FC996638B350}"), AMENDMENT]
class Win32_ComputerShutdownEvent : Win32_ComputerSystemEvent
{
  string MachineName;
  uint8  SECURITY_DESCRIPTOR[];
  uint64 TIME_CREATED;
  uint32 Type;
};

Members

The Win32_ComputerShutdownEvent class has these types of members:

Properties

The Win32_ComputerShutdownEvent class has these properties.

MachineName

Data type: string

Access type: Read-only

Qualifiers:

Name of the computer for which the event occurred.

This property is inherited from Win32_ComputerSystemEvent.

SECURITY_DESCRIPTOR

Data type: uint8 array

Access type: Read-only

Descriptor that the event provider uses to determine which users can receive the event.

This property is inherited from Win32_ComputerSystemEvent.

TIME_CREATED

Data type: uint64

Access type: Read-only

Unique value that indicates the time an event is generated. This is a 64-bit value that represents the number of 100-nanosecond intervals after January 1, 1601. The information is in the Coordinated Universal Time (UTC) format.

For more information about using uint64 values in scripts, see Scripting in WMI.

This property is inherited from Win32_ComputerSystemEvent.

Type

Data type: uint32

Access type: Read-only

The following list lists the values of the type of shutdown initiated.

Log Off (0)

"Log off"

Shutdown or Reboot (1)

"Shutdown or Reboot"

Remarks

The Win32_ComputerShutdownEvent class is derived from Win32_ComputerSystemEvent.

Win32_ComputerShutdownEvent may not work properly on local systems, as the application that receives the event may be terminated before the event is delivered. However, the event does still work for remote system shutdowns.

Requirements

Minimum supported client
Windows Vista
Minimum supported server
Windows Server 2008
Namespace
Root\CIMV2
MOF
WmiPciMa.mof
DLL
WmiPciMa.dll

See also

Win32_ComputerSystemEvent

Operating System Classes