Set-LiquitAppSettingExcludedItem

Modifies one or all Excluded Items under an Included Item. Only specified properties are changed.

Syntax

Set-LiquitAppSettingExcludedItem
    [-Parent] <AppSettingIncludedItem>
    [-ExcludedItemIndex <int>]
    [-Name <string>]
    [-Value <string>]
    [-WhatIf] [-Confirm]

Parameters

Parameter Type Position Mandatory Description
Parent AppSettingIncludedItem 0 Yes The parent Included Item. Accepts pipeline input.
ExcludedItemIndex int No Zero-based index of the specific Excluded Item to patch. If omitted, all Excluded Items are updated. Must be ≥ 0.
Name string No New display name.
Value string No New exclusion path or name. Leading \ is stripped automatically.

If ExcludedItemIndex is out of range, a non-terminating error is written and no changes are made.

If no modifiable parameter is provided, the cmdlet does nothing and returns no output.

Output: AppSettingExcludedItem

Supports: -WhatIf-Confirm

Examples

$setting      = Get-LiquitAppSetting -Name 'Outlook Settings'
$includedItem = $setting.IncludedItems[0]

# Rename the first excluded item
Set-LiquitAppSettingExcludedItem `
    -Parent             $includedItem `
    -ExcludedItemIndex  0 `
    -Name               'Exclude Cache'

# Change the exclusion path for all excluded items
Set-LiquitAppSettingExcludedItem -Parent $includedItem -Value 'Cache'