Set-WsusProduct
Set-WsusProduct
Sets whether the product representing the category of updates to synchronize is enabled or disabled.
Syntax
Parameter Set: Default
Set-WsusProduct -Product <WsusProduct> [-Disable] [-Confirm] [-WhatIf] [ <CommonParameters>]
Detailed Description
The Set-WsusProduct cmdlet enables or disables the product representing the category of updates to synchronized. In order to use this cmdlet, the Get-WsusProduct cmdlet must be run (optionally using the Where-Object cmdlet to filter its results) with its results piped into this cmdlet.
Parameters
-Disable
Specifies that updates are not to be synchronized for the specified product.
Aliases |
none |
Required? |
false |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
false |
Accept Wildcard Characters? |
false |
-Product<WsusProduct>
Specifies the product for which the updates are to be synchronized. If the Disable parameter is used, then this parameter specifies the product for which the updates are not to be synchronized. This parameter value is piped from the Get-WsusProduct cmdlet.
Aliases |
none |
Required? |
true |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
true (ByValue) |
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.
- None
Outputs
The output type is the type of the objects that the cmdlet emits.
- None
Examples
EXAMPLE 1
This example specifies that you want updates for the Antigen product.
PS C:\> Get-WsusServer | Get-WsusProduct | Where-Object –FilterScript {$_.product.title -Eq "Antigen"} | Set-WsusProduct