Export (0) Print
Expand All
Expand Minimize

Set-CMDeviceCollectionVariable

Updated: September 1, 2013

Applies To: System Center 2012 Configuration Manager SP1

Set-CMDeviceCollectionVariable

Sets the properties of a task sequence variable of a device collection in the Configuration Manager hierarchy.

Syntax

Parameter Set: SetByNameMandatory
Set-CMDeviceCollectionVariable -CollectionName <String> -VariableName <String> [-IsMask <Boolean> ] [-NewVariableName <String> ] [-NewVariableValue <String> ] [-Confirm] [-WhatIf] [ <CommonParameters>]

Parameter Set: SetByIdMandatory
Set-CMDeviceCollectionVariable -CollectionId <String> -VariableName <String> [-IsMask <Boolean> ] [-NewVariableName <String> ] [-NewVariableValue <String> ] [-Confirm] [-WhatIf] [ <CommonParameters>]

Parameter Set: SetByValueMandatory
Set-CMDeviceCollectionVariable -Collection <IResultObject> -VariableName <String> [-IsMask <Boolean> ] [-NewVariableName <String> ] [-NewVariableValue <String> ] [-Confirm] [-WhatIf] [ <CommonParameters>]




Detailed Description

The Set-CMDeviceCollectionVariable cmdlet updates the name and value of a task sequence variable.

Task sequence variables are a set of name and value pairs that provide a mechanism to configure and customize the steps of a task sequence when the task sequence is deployed to a specific collection. For more information about task sequence variables in Microsoft System Center 2012 Configuration Manager, see Planning a Task Sequence Strategy in Configuration Manager (http://go.microsoft.com/fwlink/p/?LinkID=260806) in the TechNet Library.

Parameters

-Collection<IResultObject>

Specifies an object that represents the device collection.


Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

True (ByPropertyName)

Accept Wildcard Characters?

false

-CollectionId<String>

Specifies the ID of a device collection.


Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

True (ByPropertyName)

Accept Wildcard Characters?

false

-CollectionName<String>

Specifies the name of the device collection.


Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

True (ByPropertyName)

Accept Wildcard Characters?

false

-IsMask<Boolean>

Indicates whether a value displays in the Configuration Manager console.


Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

True (ByPropertyName)

Accept Wildcard Characters?

false

-NewVariableName<String>

Specifies a name for the variable.


Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

True (ByPropertyName)

Accept Wildcard Characters?

false

-NewVariableValue<String>

Specifies a value for the variable


Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

True (ByPropertyName)

Accept Wildcard Characters?

false

-VariableName<String>

Specifies the name of the variable to update.


Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

True (ByPropertyName)

Accept Wildcard Characters?

false

-Confirm

Prompts you for confirmation before executing the command.


Required?

false

Position?

named

Default Value

false

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-WhatIf

Describes what would happen if you executed the command without actually executing the command.


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.

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: Set a task sequence variable for a device collection

This command sets the task sequence variable named New_ComputerName for the device collection named All Unknown Devices.


PS C:\> Set-CMDeviceCollectionVariable -CollectionName "All Unknown Devices" -VariableName "New_ComputerName"

Related topics

 
Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft