Set-CMUserCollection
Set-CMUserCollection
Sets the properties of one or more user collections in the Configuration Manager hierarchy.
Syntax
Parameter Set: SetByIdMandatory
Set-CMUserCollection -CollectionId <String> [-Comment <String> ] [-LimitingCollectionId <String> ] [-LimitingCollectionName <String> ] [-NewName <String> ] [-Confirm] [-WhatIf] [ <CommonParameters>]
Parameter Set: SetByNameMandatory
Set-CMUserCollection -Name <String> [-Comment <String> ] [-LimitingCollectionId <String> ] [-LimitingCollectionName <String> ] [-NewName <String> ] [-Confirm] [-WhatIf] [ <CommonParameters>]
Parameter Set: SetByValueMandatory
Set-CMUserCollection -InputObject <IResultObject> [-Comment <String> ] [-LimitingCollectionId <String> ] [-LimitingCollectionName <String> ] [-NewName <String> ] [-Confirm] [-WhatIf] [ <CommonParameters>]
Detailed Description
The Set-CMUserCollection cmdlet updates the name, description, or limiting collection of user collections.
Collections represent logical groupings of resources, such as users and devices. For more information about Microsoft System Center 2012 SP1 Configuration Manager collections, see Introduction to Collections in Configuration Manager (https://go.microsoft.com/fwlink/p/?LinkID=259433) on TechNet.
Parameters
-CollectionId<String>
Specifies the IDs of the user collections that you want to update.
Aliases |
none |
Required? |
true |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
True (ByPropertyName) |
Accept Wildcard Characters? |
false |
-Comment<String>
Specifies a description of the specified user collections.
Aliases |
none |
Required? |
false |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
True (ByPropertyName) |
Accept Wildcard Characters? |
false |
-InputObject<IResultObject>
Specifies an object that represents the user collections that you want to update.
Aliases |
none |
Required? |
true |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
True (ByPropertyName) |
Accept Wildcard Characters? |
false |
-LimitingCollectionId<String>
Specifies the ID of the limiting collection for the specified user collections.
Aliases |
LimitToCollectionId |
Required? |
false |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
True (ByPropertyName) |
Accept Wildcard Characters? |
false |
-LimitingCollectionName<String>
Specifies the name of the limiting collection for the specified user collections.
Aliases |
LimitToCollectionName |
Required? |
false |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
True (ByPropertyName) |
Accept Wildcard Characters? |
false |
-Name<String>
Specifies the names of the user collections that you want to update.
Aliases |
none |
Required? |
true |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
True (ByPropertyName) |
Accept Wildcard Characters? |
false |
-NewName<String>
Specifies a name for the specified user collections.
Aliases |
none |
Required? |
false |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
True (ByPropertyName) |
Accept Wildcard Characters? |
false |
-Confirm
Prompts you for confirmation before running the cmdlet.
Required? |
false |
Position? |
named |
Default Value |
false |
Accept Pipeline Input? |
false |
Accept Wildcard Characters? |
false |
-WhatIf
Shows what would happen if the cmdlet runs. The cmdlet is not run.
Required? |
false |
Position? |
named |
Default Value |
false |
Accept Pipeline Input? |
false |
Accept Wildcard Characters? |
false |
<CommonParameters>
This cmdlet supports the common parameters: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer, and -OutVariable. For more information, see about_CommonParameters (https://go.microsoft.com/fwlink/p/?LinkID=113216).
Inputs
The input type is the type of the objects that you can pipe to the cmdlet.
Outputs
The output type is the type of the objects that the cmdlet emits.
Examples
Example 1: Modify a user collection
This command changes the name of the user collection named UC08 to UserCollection08. The command adds a comment for the collection and specifies a limiting collection.
PS C:\> Set-CMUserCollection -Name "UC08" -Comment "User collection 08." -LimitingCollectionName "All Users" -NewName "UserCollection08"