Share via


GetEventLogCommand.InstanceId Property

Gets and sets the value of the InstanceId parameter of the Get-EventLog cmdlet. This property is introduced in Windows PowerShell 2.0.

Namespace: Microsoft.PowerShell.Commands
Assembly: Microsoft.PowerShell.Commands.Management (in Microsoft.PowerShell.Commands.Management.dll)

Usage

'Usage
Dim instance As GetEventLogCommand
Dim value As Long()

value = instance.InstanceId

instance.InstanceId = value

Syntax

'Declaration
<ParameterAttribute(Position:=1, ParameterSetName:="LogName")> _
<ValidateNotNullOrEmptyAttribute> _
<ValidateRangeAttribute(0, 9223372036854775807)> _
Public Property InstanceId As Long()
[ParameterAttribute(Position=1, ParameterSetName="LogName")] 
[ValidateNotNullOrEmptyAttribute] 
[ValidateRangeAttribute(0, 9223372036854775807)] 
public long[] InstanceId { get; set; }
[ParameterAttribute(Position=1, ParameterSetName=L"LogName")] 
[ValidateNotNullOrEmptyAttribute] 
[ValidateRangeAttribute(0, 9223372036854775807)] 
public:
property array<long long>^ InstanceId {
    array<long long>^ get ();
    void set (array<long long>^ value);
}
/** @property */
public long[] get_InstanceId ()

/** @property */
public void set_InstanceId (long[] value)
public function get InstanceId () : long[]

public function set InstanceId (value : long[])

Property Value

An Int64 array that specifies the instance identifiers of the events to be retrieved.

Remarks

This topic is included in this SDK for completeness only. For more information about this cmdlet, see Get-EventLog in the Microsoft TechNet library.

For Help at the command line, type:

get-help get-eventlog

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Platforms

Target Platforms

See Also

Reference

GetEventLogCommand Class
GetEventLogCommand Members
Microsoft.PowerShell.Commands Namespace

Other Resources

Windows PowerShell SDK