Set-SCDriverPackage

Updates the properties of an existing driver package object.

Syntax

Set-SCDriverPackage [-DriverPackage] <DriverPackage> [-JobVariable <String>] [-PROTipID <Guid>]
 [-RunAsynchronously] -Tag <System.Collections.Generic.List`1[System.String]> [-VMMServer <ServerConnection>]
 [<CommonParameters>]

Description

The Set-SCDriverPackage cmdlet updates the properties of an existing driver package object.

Examples

Example 1: Update the tags for a set of driver packages

PS C:\> $Drivers = Get-SCDriverPackage -Tag "Production"
PS C:\> ForEach ($Driver in $Drivers) {Set-SCDriverPackage -DriverPackage $Driver -Tag {Production, NewTag}}

The first command gets all driver package objects that have a tag value of Production and stores the objects in the $Drivers object array.

The second command uses the ForEach statement to add the value "NewTag" to each driver package object stored in $Drivers.

For information about the PowerShell ForEach statement, type Get-Help about_Foreach.

Parameters

-DriverPackage

Specifies a driver package object.

Type:DriverPackage
Required:True
Position:0
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False
-JobVariable

Specifies that job progress is tracked and stored in the variable named by this parameter.

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

Specifies the ID of the Performance and Resource Optimization tip (PRO tip) that triggered this action. This parameter lets you audit PRO tips.

Type:Guid
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-RunAsynchronously

Indicates that the job runs asynchronously so that control returns to the command shell immediately.

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

Specifies a word or phrase to associate with an object so that you can search for all objects with the specified set of tags. You can search for a subset of tags, or you can search for the full set of tags.

Type:System.Collections.Generic.List`1[System.String]
Required:True
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-VMMServer

Specifies a Virtual Machine Manager (VMM) server object.

Type:ServerConnection
Required:False
Position:Named
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False

Outputs

DriverPackage[]

This cmdlet returns an array of **DriverPackage** objects.