
- Export outlook contacts to csv 2010 how to#
- Export outlook contacts to csv 2010 code#
You’ll notice a file being downloaded with the extension. Finally, click the “ Export” button near the top of window. Then select the option “Contacts from this folder” and choose the folder you created. To export specific contacts, create a folder with the specific contacts ahead of time. Choose where you want to export your contacts from. Choose “ Export Contacts” from the dropdown window that appears. Your contacts will now be in your contact list. You should get a message saying the import was successful. csv file has been chosen, click the “ Upload” button near the top of the window. Click the “ Browse” button and choose the. csv file is from OWA using the Outlook 2010, 2013, or 2016 option will work. Choose the location from which you are importing the contacts. Choose “ Import Contacts” from the dropdown window that appears. Click on the “ Manage” button near the top of the window. To fix this, use a program like Excel to split the file into two. In addition to this, keep in mind that you cannot import more than 2,000 contacts at once since the. Set objSourceItems = objSourceFolder.*It’s important to keep in mind that if you import a contact that is already in your contacts, it will make a duplicate. ObjSourceFolder.CopyTo objDestinationFolder , vbOKOnly + vbExclamation, "Invalid Folder" MsgBox "Please pick a destination folder that is of the same default item type as the source folder." _ If objDestinationFolder.DefaultItemType objSourceFolder.DefaultItemType Then If objDestinationFolder Is Nothing Then GoTo Exitt: 'User cancelled Set objDestinationFolder = objNS.PickFolder MsgBox "In the next dialog, please select the destination folder where you want the folder items copied to.", vbOKOnly MsgBox "In the next dialog, please select the parent folder where you want the new folder copied to.", vbOKOnly & " will also be copied.", vbYesNo + vbQuestion, "Select Copy Type") = vbYes Then If MsgBox("Do you wish to copy the entire folder? Click 'No' to copy just the contents of the folder. If objSourceFolder Is Nothing Then GoTo Exitt: 'User cancelled MsgBox "In the next dialog, please select the source folder containing the items you want to copy.", vbOKOnly ObjOutputFile.WriteLine objAppointment.Subject & "," & objAppointment.Start & "," & objAppointment.Endĭim objSourceItem As Object, objCopy As Objectĭim objSourceFolder As Outlook.MAPIFolderĭim objDestinationFolder As Outlook.MAPIFolder ObjOutputFile.WriteLine "Subject,Start,End"įor Each objAppointment In objAppointments
Set objOutputFile = objFS.OpenTextFile("C:\Temp\AppointmentExport.csv", ForWriting _ Set objFS = New Scripting.FileSystemObject Set objAppointments = objCalendarFolder.Items Set objCalendarFolder = objNS.GetDefaultFolder(olFolderCalendar) Set objNS = Application.GetNamespace("MAPI") 'You must set a reference to the Microsoft Scripting Runtime library to use the FileSystemObjectĭim objAppointments As Outlook.Items, objCalendarFolder As Outlook.MAPIFolderĭim objAppointment As Outlook.AppointmentItemĭim objFS As Scripting.FileSystemObject, objOutputFile As Scripting.TextStream
You may find the following sample code helpful (listed in the VBA script to export Calendar to PST and CSV forum thread): Sub ExportAppointmentsToCSVFile()
The How to automate Outlook from another program article describes all the required steps. Instead of exporting and then importing the required data you may consider automating Outlook from Access.