To read the default value of a key :
(get-itemproperty -literalpath HKLM:\SOFTWARE\Classes\.txt).'(default)'
To create a default value :
New-ItemProperty -LiteralPath HKLM:\SOFTWARE\Classes\.txt -name '(Default)' -Value "txtfile"
To set an existing default value :
Set-ItemProperty -LiteralPath HKLM:\SOFTWARE\Classes\.txt -name '(Default)' -Value "txtfile"
No comments:
Post a Comment