OL2002: Restrict May Not Work with Uncached Properties (292451)
The information in this article applies to:
This article was previously published under Q292451 SYMPTOMS
You use the Restrict and IncludeRecurrences methods in the Outlook object model and Outlook appears to stop responding (hang), or the collection of items does not appear to be functioning correctly.
CAUSE
This may happen if all of the following are true:
- You have items that recur and do not have an end date.
- In the filter of the Restrict method, you did not specify an end date, so the number of items in the collection is infinite.
- In the filter of the Restrict method, you used a property that Outlook does not cache by default.
RESOLUTION
Use one of the following workarounds: - Use the SetColumns method to cache the property you wish to use Restrict on. As an example, uncomment the SetColumns line in the "Steps to Reproduce the Problem" section below.
- Alter the filter of the Restrict method so that the method will not return an infinite collection.
REFERENCESFor additional information about available resources and answersto commonly asked questions about Microsoft Outlook solutions, click the article number below
to view the article in the Microsoft Knowledge Base:
287530 OL2002: Questions About Custom Forms and Outlook Solutions
Modification Type: | Major | Last Reviewed: | 6/23/2005 |
---|
Keywords: | kbnofix kbprb KB292451 |
---|
|