Need to generate a report of users with Local admin rights on their PC but execlude certain local admin accounts. The names of the account i need to execlude are Administrator, Company name, Domain name\Domain Admins , Domain name\gg-ap-helpdesktechs
 If these domain accounts + usernames are included i will get a report on all PC's in our company. I just want a report of the machines that a standard users has local admin rights on.

0 Comments   [ - ] Hide Comments


Please log in to comment

Answer this question or Comment on this question for clarity



I went to using a CSV export and open that in excel, run a search and replace macro to remove all the unwanted admin names. I saved that sheet with the macro's and now all I have to do is cut and paste from the CSV to the macro enabled sheet (.xlsm) and run the macros, (takes 2 minutes) and then save to a non macro sheet (xlsx) to give to the staff who needs this data.

To create my master spread sheet, I did an export to CSV and opened that in excell.  I used the record function to create 2 macros.

The raw CSV:

The first removed the garbage text, which leaves me with a report of all admins including the ones we want to make sure no one has deleted the users/groups we want to be admins.

after 1st run

The second removes the approved admins to leave others.  I then do a data sort by admin user, delete all the rows without anything in the admin cells resort by machine name.

after 2 marcos

I use a custom software inventory to gather the raw data and then a report to export to CSV.

Answered 05/15/2014 by: SMal.tmcc
Red Belt

Please log in to comment