Tool to Export DL Membership

Here is a small HTA applet that I have built to export the membership of various groups in Windows Active Directory. It provides some basic filtering (owner, specific OU, name contains), plus 3 modes of export, XLS, CSV, or HTML to screen. Beware, if you have office 2007, XLS is XLSX format.

To run this in your environment, it will need to be modified:
line 27 & 28

 strHTML=strhtml&"<option value=""LDAP://dc=local,dc=corp"" >All OUs"
strHTML=strhtml&"<option value=""LDAP://ou=sub,dc=local,dc=corp"" >This SUB OU Only"

line 55 & 56

strHTML=strhtml&"<option value=""LDAP://dc=local,dc=corp"" >All OUs"
strHTML=strhtml&"<option value=""LDAP://ou=sub,dc=local,dc=corp"" >This SUB OU Only"

CSV mode gives the best detail as XLS has a 255 character limit on single fields.

Just fixed issue where it required you to pick a subOU in order to continue.

AttachmentSize
DL Export Report.zip6.3 KB

Find ALL DLs that a specific person manages

Friend is working on the dirty deed of removing a series of accounts from AD. As part of that clean-up he is to find all the distribution lists that each account is assigned manager on. Using the Quest ActiveRoles Powershell tools, you can quickly find these unfortunate people using:

$selectUser = Get-QADUser "John Doe"
Get-QADGroup -SizeLimit 0  -ldapFilter '(&(mail=*)(managedby=*))' | where {$_.managedby -eq $selectUser}  | select displayname, managedby