Announcement

Collapse
No announcement yet.

Outlook-Kontakte mit C# auslesen

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Outlook-Kontakte mit C# auslesen

    Hallo,<BR>
    kann mir jeman eine Hilfestelung zum Auslesen von Outlook-Kontakten geben?<BR>
    Ein Link oder Code-Beispiel würde schon helfen.<BR>
    Danke.<BR>
    Gruß Börge

  • #2
    1. outlook.dll herstellen: <BR>
    tlbimp "C:\Programme\Microsoft Office\Office\MSOUTL9.OLB" /oututlook.dll<BR>
    2. im Programm:<BR>
    using outlook;<BR>
    ...<BR>
    outlook.Application appl = new outlook.Application();<BR>
    outlook.MAPIFolder f = appl.Session.GetDefaultFolder(outlook.OlDefaultFol ders.olFolderContacts);<BR>
    int count = f.Items.Count;<BR>
    for(int i = 1; i <= count - 1; i++)<BR>
    {<BR>
    outlook.ContactItem c = (outlook.ContactItem) f.Items.Item(i);<BR>
    ... = c.LastName;<BR>
    ... = c.FirstName;<BR>
    ... = c.Email1Address;<BR>
    ... usw...<BR>
    }<BR&gt

    Comment

    Working...
    X