Move-CMObject

Moves a Configuration Manager object into a different folder.

Syntax

Move-CMObject
    [-Confirm]
    [-DisableWildcardHandling]
    -FolderPath <String>
    [-ForceWildcardHandling]
    -InputObject <IResultObject[]>
    [-WhatIf]
    [<CommonParameters>]
Move-CMObject [-Confirm] [-DisableWildcardHandling] -FolderPath  [-ForceWildcardHandling]
 -ObjectId  [-WhatIf] []

Description

The Move-CMObject cmdlet moves a Microsoft System Center Configuration Manager object into a different folder. Specify the object to move and the destination folder. Because an object exists in only one folder, the cmdlet does not specify the current folder.

Examples

Example 1: Move an object

PS C:\>Move-CMObject -FolderPath "GKP:\Application\TestFolder" -ObjectId "209224563"

This command moves the object that has the specified ID to the folder GKP:\Application\TestFolder.

Required Parameters

-FolderPath

Specifies a destination folder path, in the following format: AAA:\<object type>\folder\sub-folder\subfolder, where AAA represents the Configuration Manager site code. For example, a folder that is named LOB Apps for an application node at a sight designated CM1 has the following file path: CM1:\Application\LOB Apps.

Type:String
Required:True
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-InputObject

Specifies an array of Configuration Manager objects to move.

Type:IResultObject[]
Required:True
Position:Named
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False
-ObjectId

Specifies an array of IDs of objects to move.

Type:String[]
Aliases:InstanceKey
Required:True
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False

Optional Parameters

-Confirm

Prompts you for confirmation before running the cmdlet.

Type:SwitchParameter
Aliases:cf
Required:False
Position:Named
Default value:False
Accept pipeline input:False
Accept wildcard characters:False
-DisableWildcardHandling

Indicates that wildcard handling is disabled.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-ForceWildcardHandling

Indicates that wildcard handling is enabled.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

Type:SwitchParameter
Aliases:wi
Required:False
Position:Named
Default value:False
Accept pipeline input:False
Accept wildcard characters:False