IvoDijkgraaf
6/26/2015 - 12:51 PM

Get Last Logon time for computers from Active Directory

Get Last Logon time for computers from Active Directory

Get-Content C:\Computers.txt | 
    Get-ADComputer -Properties Name,LastLogonDate |
    Select Name,LastLogonDate |
    Export-Csv C:\LastLogon.csv -NoTypeInformation