Remove-CMUserCollectionIncludeMembershipRule

Removes an include membership rule from one or more user collection in the Configuration Manager hierarchy.

Syntax

Remove-CMUserCollectionIncludeMembershipRule
      -CollectionId <String>
      -IncludeCollection <IResultObject>
      [-Force]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]
Remove-CMUserCollectionIncludeMembershipRule
      -CollectionId <String>
      -IncludeCollectionId <String>
      [-Force]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]
Remove-CMUserCollectionIncludeMembershipRule
      -CollectionId <String>
      -IncludeCollectionName <String>
      [-Force]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]
Remove-CMUserCollectionIncludeMembershipRule
      -CollectionName <String>
      -IncludeCollectionName <String>
      [-Force]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]
Remove-CMUserCollectionIncludeMembershipRule
      -CollectionName <String>
      -IncludeCollection <IResultObject>
      [-Force]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]
Remove-CMUserCollectionIncludeMembershipRule
      -CollectionName <String>
      -IncludeCollectionId <String>
      [-Force]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]
Remove-CMUserCollectionIncludeMembershipRule
      -InputObject <IResultObject>
      -IncludeCollection <IResultObject>
      [-Force]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]
Remove-CMUserCollectionIncludeMembershipRule
      -InputObject <IResultObject>
      -IncludeCollectionId <String>
      [-Force]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]
Remove-CMUserCollectionIncludeMembershipRule
      -InputObject <IResultObject>
      -IncludeCollectionName <String>
      [-Force]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]

Description

The Remove-CMUserCollectionIncludeMembershipRule cmdlet removes an include rule from the specified collections. You can specify the user collections by using their names, IDs, or by specifying an input object that represents the collections.

For more information about collection rules in Microsoft System Center Configuration Manager, see Introduction to Collections in Configuration Manager on TechNet.

Examples

Example 1: Remove an include membership rule from a user collection

PS C:\> Remove-CMUserCollectionIncludeMembershipRule -CollectionId "9990000D" -IncludeCollectionId "SMSDM001"

This command removes the include membership rule that has the ID SMSDM001 from the user collection that has the ID 9990000D.

Required Parameters

-CollectionId
Type:String
Aliases:Id
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-CollectionName
Type:String
Aliases:Name
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-IncludeCollection
Type:IResultObject
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-IncludeCollectionId
Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-IncludeCollectionName
Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-InputObject
Type:IResultObject
Aliases:Collection
Position:Named
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False

Optional Parameters

-Confirm

Prompts you for confirmation before running the cmdlet.

Type:SwitchParameter
Aliases:cf
Position:Named
Default value:False
Accept pipeline input:False
Accept wildcard characters:False
-Force
Type:SwitchParameter
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
Position:Named
Default value:False
Accept pipeline input:False
Accept wildcard characters:False