Quantcast
Channel: Hey, Scripting Guy! Blog
Viewing all articles
Browse latest Browse all 3333

PowerTip: Use PowerShell to Find Parameters for CIM Class Method

$
0
0

Summary: Learn how to discover the parameters for a method in a CIM class.

Hey, Scripting Guy! Question How can I find the parameters of a CIM class method, such as GetStringValue in the StdRegprov class?

Hey, Scripting Guy! Answer Use Get-CimClass to get the class:

$class = Get-CimClass -ClassName StdRegProv

To view the methods:

$class.CimClassMethods

To view the parameters of a particular method:

$class.CimClassMethods["GetStringValue"].Parameters

You will see the parameter name and data type. The qualifiers will tell you if it’s an input or output parameter.


Viewing all articles
Browse latest Browse all 3333

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>