Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Const olFolderContacts = 10
- Set objOutlook = CreateObject("Outlook.Application")
- Set objNamespace = objOutlook.GetNamespace("MAPI")
- Set colContacts = objNamespace.GetDefaultFolder(olFolderContacts).Items
- intCount = colContacts.Count
- For i = 1 To intCount
- If TypeName(colContacts.Item(i)) = "DistListItem" Then
- Set objDistList = colContacts.Item(i)
- Wscript.Echo objDistList.DLName
- For j = 1 To objDistList.MemberCount
- Wscript.Echo objDistList.GetMember(j).Name & " -- " & _
- objDistList.GetMember(j).Address
- Next
- Wscript.Echo
- End If
- Next
Add Comment
Please, Sign In to add comment