Quantcast
Channel: Windows PowerShell forum
Viewing all articles
Browse latest Browse all 21975

Help getting output

$
0
0

What my script does is querys AD for computers added within the last 90 days then get the user logged in and the computer name. How was I add the whencreated to the output list?

Get-ADComputer -Filter * -Properties whenCreated | ? { ((Get-Date) - $_.whenCreated).Days -lt 90}| select whencreated,name |
Foreach-Object { Get-WmiObject Win32_ComputerSystem -cn $_.name -EA silentlyContinue |
Select-Object USername,Caption,Manufacturer } 


Viewing all articles
Browse latest Browse all 21975

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>