ConvertFrom-CMIResultObject
Converts from an IResultObject to a ManagementBaseObject.
Syntax
ConvertFrom-CMIResultObject
-InputObject <IResultObject>
[-DisableWildcardHandling]
[-ForceWildcardHandling]
[<CommonParameters>]
Description
The Convertfrom-CMIResultObject cmdlet converts from an IResultObject to a ManagementBaseObject.
Note
Run Configuration Manager cmdlets from the Configuration Manager site drive, for example PS XYZ:\>
. For more information, see getting started.
Examples
Example 1: Convert an IResultObject to a ManagementBaseObject by getting a site object
PS ABC:\> $Site = Get-CMSite -SiteCode PS1
PS ABC:\> ConvertFrom-CMIResultObject -InputObject $Site
The first command gets the site object with the code PS1 and stores the object in the $Site variable.
The second command converts the site stored in $Site to a ManagementBaseObject.
Example 2: Convert an IResultObject to a ManagementBaseObject by getting a site by its code
PS ABC:\> ConvertFrom-CMIResultObject -InputObject (Get-CMSite -SiteCode PS2)
This command gets the site with the code PS2 and then converts the site to a ManagementBaseObject.
Parameters
-DisableWildcardHandling
This parameter treats wildcard characters as literal character values. You can't combine it with ForceWildcardHandling.
Type: | SwitchParameter |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-ForceWildcardHandling
This parameter processes wildcard characters and may lead to unexpected behavior (not recommended). You can't combine it with DisableWildcardHandling.
Type: | SwitchParameter |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-InputObject
Specifies the IResultObject to convert to a ManagementBaseObject.
Type: | IResultObject |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
Inputs
Microsoft.ConfigurationManagement.ManagementProvider.IResultObject
Outputs
System.Object