SvennD
Export all windows domain computers to CSV from windows
April 18, 2019

Export all windows domain computers to CSV from windows

Posted on April 18, 2019  •  1 minutes  • 95 words  •  Suggest Changes

Doesn’t happen often that I need Windows tools, but this worked nicely, so I though I share it with the future me that will have forgotten about this method;

On the domain server open a “Windows Powershell”;

Import the module :

Import-Module ActiveDirectory

Then create the list of “enabled” users :

Get-ADComputer -Filter {enabled -eq $true} -properties *|select Name, OperatingSystem, LastLogonDate

This wil result in :

To export it in CSV :

Get-ADComputer -Filter {enabled -eq $true} -properties *|select Name, OperatingSystem, LastLogonDate | export-csv my_export.csv

Will create a file my_export.csv in csv format ! Enjoy.

Support

If you enjoyed this website, consider buying me a Dr. Pepper

Buy me a Dr PepperBuy me a Dr Pepper