![]() |
Outlook 2007 Links.Item - what is returned?
In Outlook 2003 I my code included accessing data in a contact item by
passing a an item from the Links collection. The code was ,object = object.Links.Item(1).Item. That worked fine for months. On upgrading to 2007 B2TR I had to remove the .Item bit at the end. The code ran OK. Suddenly accessing the object returned (which should be an olContact results in an eroor - the object does not support that method or property. The debuffer declares the object to be of class "Link". Why has the Links.Item(index) stopped returning an object of class olContact? |
Outlook 2007 Links.Item - what is returned?
Links.Item(index) will return a Link object. Link.Item will return either a ContactItem or Nothing. Your code needs to be able to handle both possible outcomes.
-- Sue Mosher, Outlook MVP Author of Configuring Microsoft Outlook 2003 http://www.turtleflock.com/olconfig/index.htm and Microsoft Outlook Programming - Jumpstart for Administrators, Power Users, and Developers http://www.outlookcode.com/jumpstart.aspx "David Hyde" wrote in message ... In Outlook 2003 I my code included accessing data in a contact item by passing a an item from the Links collection. The code was ,object = object.Links.Item(1).Item. That worked fine for months. On upgrading to 2007 B2TR I had to remove the .Item bit at the end. The code ran OK. Suddenly accessing the object returned (which should be an olContact results in an eroor - the object does not support that method or property. The debuffer declares the object to be of class "Link". Why has the Links.Item(index) stopped returning an object of class olContact? |
All times are GMT +1. The time now is 06:49 AM. |
Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2006 OutlookBanter.com