Remove a key value pair from an existing hash table

suggest change

Hashtable.Remove takes the key. This removes the Key2 entry:

$hashTable = @{
    Key1 = 'Value1'
    Key2 = 'Value2'
}
$hashTable.Remove("Key2")
$hashTable

#Output

Name                           Value
----                           -----
Key1                           Value1

Feedback about page:

Feedback:
Optional: your email if you want me to get back to you:



Table Of Contents