You are currently viewing PowerShell Get-ItemProperty Cmdlet

PowerShell Get-ItemProperty Cmdlet

PowerShell Get-ItemProperty Cmdlet

Hello Everyone

Welcome to CloudAffaire and this is Debjeet.

In the last blog post, we have discussed Set-Item cmdlet in PowerShell.

https://cloudaffaire.com/powershell-set-item-cmdlet/

In this blog post, we will discuss Get-ItemProperty cmdlet in PowerShell. You can use Get-ItemProperty cmdlet to get the properties of a specific item. Get-ItemProperty cmdlet is mainly used to get property of a file, directory or registry key in PowerShell. You define the location of the item using ‘path’ argument and property to retrieve using ‘name’ argument.

Get-ItemProperty Cmdlet Syntax:

Get-ItemProperty Cmdlet Argument List:

  • Credential: To impersonate another user or elevate your credentials.
  • Exclude: Specifies, as a string array, an item or items that this cmdlet excludes from the operation. The value of this parameter qualifies the Path parameter.
  • Filter: Specifies a filter in the format or language of the provider. The value of this parameter qualifies the Path parameter.
  • Include: Specifies, as a string array, an item or items that this cmdlet includes in the operation. The value of this parameter qualifies the Path parameter.
  • LiteralPath: Specifies the path to the current location of the property. Unlike the Path parameter, the value of LiteralPath is used exactly as it is typed.
  • Name: Specifies the name of the property or properties to retrieve.
  • Path: Specifies the path to the item or items.
  • UseTransaction: Includes the command in the active transaction. This parameter is valid only when a transaction is in progress.

PowerShell Get-ItemProperty Cmdlet:

List The Contents Of A Directory In PowerShell:

Get Properties Of A Directory In PowerShell:

Get Properties Of A File In PowerShell:

Get Properties Of A Registry Key In PowerShell:

Hope you have enjoyed this article. In the next blog post, we will discuss Set-ItemProperty cmdlet in PowerShell.

To Set more details on PowerShell, kindly follow below official documentation

https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about?view=powershell-5.1

 

Leave a Reply