ContactCollection Class

Windows Mobile 6.5

Represents the collection of Contact items in a Contact folder.

Namespace: Microsoft.WindowsMobile.PocketOutlook
Assembly: Microsoft.WindowsMobile.PocketOutlook (in microsoft.windowsmobile.pocketoutlook.dll)

public class ContactCollection : PimItemCollection, IEnumerable


The code below shows how to data bind a combo box to the list of contacts. In this case, the "FileAs" property will be displayed on the combo box, the "ItemId" property will be the property used for comboBox1.SelectedValue.

OutlookSession mySession = new OutlookSession();
this.comboBox1.DataSource = this.mySession.Contacts.Items;
this.comboBox1.DisplayMember = "FileAs";
this.comboBox1.ValueMember = "ItemId";

Any public static (Shared in Visual Basic) members of this type are thread-safe. Any instance members are not guaranteed to be thread-safe.