![]() |
If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Search this Thread | Display Modes |
#1
|
|||
|
|||
![]()
Hello all,
I need to write a VBA script that will export the members of a Exchange Distribution List into a CSV (or a semicolon delimited txt). I did find the following code snippet from Microsoft that runs in a cmd shell. Could someone please help me convert this into a valid VBA script to export the list in Excel? I am running Outlook 2003 in a Windows 2000 enviroment with Exchange 2000. (don't ask me why.) Thanks Matt [Code} Const olFolderContacts = 10 Set objOutlook = CreateObject("Outlook.Application") Set objNamespace = objOutlook.GetNamespace("MAPI") Set colContacts = objNamespace.GetDefaultFolder(olFolderContacts).It ems 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 [End Code} |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
How do I export my Outlook Address Book in CSV format? | Mojohn3 | Outlook - Using Contacts | 3 | August 30th 09 04:22 AM |
Outlook 2003 no longer allows export of contact data to a CSV | James Borders | Outlook - Using Contacts | 2 | March 18th 06 08:49 PM |
I want a csv export of my outlook contacts but I only get the pst | Johnny | Outlook - Using Contacts | 4 | March 8th 06 05:58 AM |
Export contacts to CSV | steve | Outlook - Using Contacts | 2 | February 28th 06 06:59 PM |
how to export contacts to .csv file | qalias | Outlook - Using Contacts | 7 | January 25th 06 06:01 AM |