My latest article on PowerShell Magazine is on how to use Shell.Application Com object to display extended file attributes in PowerShell. Because this is heavily dependent on the Windows version and localization this does present some challenges. The full article containing tips on how to use this class is available on PowerShell Magazine : Use Shell.Application to display extended file attributes
The following example will list the first three attributes using the Shell.Application object:
$com = (New-Object -ComObject Shell.Application).NameSpace('C:\') $com.Items() | ForEach-Object { New-Object -TypeName PSCustomObject -Property @{ Name = $com.GetDetailsOf($_,0) Size = $com.GetDetailsOf($_,1) ItemType = $com.GetDetailsOf($_,2) } } |
For more articles like this, have a look at the External Articles section of my blog, it contains all the articles I have posted on external sources such as PowerShell Magazine. The article posted on PowerShell magazine contains a link to my Get-ExtensionAttribute script in the TechNet Script Gallery.
Links in this Article |
PSTip: Use Shell.Application to display extended file attributes |
PowerShell Magazine |
External Articles |
Get-ExtensionAttribute |
My entries in TechNet Script Gallery |