Hi, I'm trying to write the same app but for a console application. I'm not really familiar with c++ so I'm not sure what to do.
Could someone tell me which changes I have to make to make this work (I'm trying to do this so later on I can export the contacts to a java app).
I had been looking for a way to extract calendar data from Outlook 2000 and this code works well for that too. Just replace _ContactItemPtr with _AppointmentItemPtr and use GetDefaultFolder(olFolderCalendar). I've been having a hard time finding any good documentation from Microsoft on using these classes in VC, so I've been stuck decoding the header files. Still, this code provides a great launching point for accessing more than just Outlook contacts.
it's elegant concept. The problem I have:
'GetEmail1Address' returns just string like here: '/o=XYZ/ou=ABC012/cn=Recipients/cn=Firstname Lastname'
'GetEmail2Address' and 'GetEmail3Address' return empty string.
Is there a way to enumerate the namespaces that can be retrieved? You get the 'MAPI' namespace each time - but that returns no contacts to me - even though when I open up Outlook I've got dozens. I'm assuming that my user is not set up as an exchange user, and so has no Mapi entries... but there must still be a way.