Z
zzozo
Hi, all.
I created a test addin in c#.net for outlook 2000, and it works ok.
However, when I close the outlook, it doesn't exit... My code is
simple... It is located in onConnection(). Can anybody see the
problem??
===============================================================
NameSpace objNS = applicationObject.GetNamespace("MAPI");
MAPIFolder contacts =
objNS.GetDefaultFolder(OlDefaultFolders.olFolderContacts);
ContactItem c;
for ( int i=1; i<= contacts.Items.Count; i++ )
{
c = (ContactItem)contacts.Items.Item(i);
MessageBox.Show(c.FirstName + " " + c.LastName);
}
===============================================================
I created a test addin in c#.net for outlook 2000, and it works ok.
However, when I close the outlook, it doesn't exit... My code is
simple... It is located in onConnection(). Can anybody see the
problem??
===============================================================
NameSpace objNS = applicationObject.GetNamespace("MAPI");
MAPIFolder contacts =
objNS.GetDefaultFolder(OlDefaultFolders.olFolderContacts);
ContactItem c;
for ( int i=1; i<= contacts.Items.Count; i++ )
{
c = (ContactItem)contacts.Items.Item(i);
MessageBox.Show(c.FirstName + " " + c.LastName);
}
===============================================================