Messenger Plus! Live - Scripting Documentation

The Contacts object can be iterated through the Enumerator object of JScript.

Return Value

A Contact object.

The iterator typically fails for the following reason:

Remarks

Each Contacts object keeps track of its own iterator. This means that even if two objects refer to the same collection of contacts, they'll contain two different iterators. This is why Contacts objects must first be assigned to variables before being used in an Enumerator.

Example

The current user must be signed for this code to succeed.

Debug.Trace("Contacts in the user's contact list:");
var Contacts = Messenger.MyContacts;
var e = new Enumerator(Contacts);
for(; !e.atEnd(); e.moveNext())
{
	var Contact = e.item();
	Debug.Trace(" " + Contact.Email);
}

Function Information

ObjectContacts
AvailabilityMessenger Plus! Live 4.00

See Also

Contacts Object, Contact Object, JScript's Enumerator Object.