Contact Info

Crumbtrail

ActiveXperts.com » Administration » Powershell » Powershell 3.0 » Invoke-CimMethod

Invoke-CimMethod - Powershell 3.0 CmdLet

ActiveXperts Network Monitor ships with integrated Powershell scripts to monitor complex network. The scripts run out of the box
Download the ActiveXperts Network Monitor FREE version now »

Invoke-CimMethod

Short description
Invokes a method of a CIM class.

Syntax
Invoke-CimMethod [-ClassName] <String> [[-Arguments] <IDictionary>] [-MethodName] <String> [-ComputerName <String[]>] [
-Namespace <String>] [-OperationTimeoutSec <UInt32>] [-Confirm] [-WhatIf] [<CommonParameters>]
Invoke-CimMethod [-CimClass] <CimClass> [[-Arguments] <IDictionary>] [-MethodName] <String> [-OperationTimeoutSec <UInt
32>] -CimSession <CimSession[]> [-Confirm] [-WhatIf] [<CommonParameters>]
Invoke-CimMethod [-CimClass] <CimClass> [[-Arguments] <IDictionary>] [-MethodName] <String> [-ComputerName <String[]>] 
[-OperationTimeoutSec <UInt32>] [-Confirm] [-WhatIf] [<CommonParameters>]
Invoke-CimMethod [-InputObject] <CimInstance> [[-Arguments] <IDictionary>] [-MethodName] <String> [-OperationTimeoutSec
 <UInt32>] [-ResourceUri <Uri>] -CimSession <CimSession[]> [-Confirm] [-WhatIf] [<CommonParameters>]
Invoke-CimMethod [-ClassName] <String> [[-Arguments] <IDictionary>] [-MethodName] <String> [-Namespace <String>] [-Oper
ationTimeoutSec <UInt32>] -CimSession <CimSession[]> [-Confirm] [-WhatIf] [<CommonParameters>]
Invoke-CimMethod [[-Arguments] <IDictionary>] [-MethodName] <String> [-Namespace <String>] [-OperationTimeoutSec <UInt3
2>] [-QueryDialect <String>] -CimSession <CimSession[]> -Query <String> [-Confirm] [-WhatIf] [<CommonParameters>]
Invoke-CimMethod [[-Arguments] <IDictionary>] [-MethodName] <String> [-Namespace <String>] [-OperationTimeoutSec <UInt3
2>] -CimSession <CimSession[]> -ResourceUri <Uri> [-Confirm] [-WhatIf] [<CommonParameters>]
Invoke-CimMethod [[-Arguments] <IDictionary>] [-MethodName] <String> [-ComputerName <String[]>] [-Namespace <String>] [
-OperationTimeoutSec <UInt32>] -ResourceUri <Uri> [-Confirm] [-WhatIf] [<CommonParameters>]
Invoke-CimMethod [-InputObject] <CimInstance> [[-Arguments] <IDictionary>] [-MethodName] <String> [-ComputerName <Strin
g[]>] [-OperationTimeoutSec <UInt32>] [-ResourceUri <Uri>] [-Confirm] [-WhatIf] [<CommonParameters>]
Invoke-CimMethod [[-Arguments] <IDictionary>] [-MethodName] <String> [-ComputerName <String[]>] [-Namespace <String>] [
-OperationTimeoutSec <UInt32>] [-QueryDialect <String>] -Query <String> [-Confirm] [-WhatIf] [<CommonParameters>]





Description
The Invoke-CimMethod cmdlet invokes a method of a CIM class or CIM instance using the name-value pairs specified by the
 Arguments parameter.


If the InputObject parameter is not specified, the cmdlet works in one of the following ways: 

--If neither the ComputerName parameter nor the CimSession parameter is specified, then this cmdlet works on local Wind
ows Management Instrumentation (WMI) using a Component Object Model (COM) session. 
--If either the ComputerName parameter or the CimSession parameter is specified, then this cmdlet works against the CIM
 server specified by either the ComputerName parameter or the CimSession parameter.


If the InputObject parameter is specified, the cmdlet works in one of the following ways: 

--If neither the ComputerName parameter nor the CimSession parameter is specified, then this cmdlet uses the CIM sessio
n or computer name from the input object. 
--If the either the ComputerName parameter or the CimSession parameter is specified, then this cmdlet uses the either t
he CimSession parameter value or ComputerName parameter value. Note: This is not very common.