I have the following script.
Get-Content comps.csv | Get-ChildItem 'HKLM:\SOFTWARE\Microsoft\NET Framework Setup\NDP' -recurse | Get-ItemProperty -name Version,Release -EA 0 | Where { $_.PSChildName -match '^(?!S)\p{L}'} | Select PSChildName, Version, Release
My comps.csv content
Name,Type,Description,
ALYTAUS-PC,Computer,,
AUGUSTE-PC,Computer,,
AUSRA-PC,Computer,,
BIRZU-PC,Computer,,
VYTAUTO-PC1,Computer,,
I got that message for each object in csv:
Get-ChildItem : The input object cannot be bound to any parameters for the command either because the command does n
ot take pipeline input or the input and its properties do not match any of the parameters that take pipeline input.
At line:1 char:38
+ Get-Content comps.csv | Get-ChildItem <<<< 'HKLM:\SOFTWARE\Microsoft\NET Framework Setup\NDP' -recurse |
+ CategoryInfo : InvalidArgument: (VYTAUTO-PC1,Computer,,:PSObject) [Get-ChildItem], ParameterBindingE
xception
+ FullyQualifiedErrorId : InputObjectNotBound,Microsoft.PowerShell.Commands.GetChildItemCommand