You really should be declaring all the Items collections you are working
with at class level and not inside methods. I can see the GC getting rid of
those at random intervals. Or you can create wrapper classes for folders and
declare the Items collection and folder entities at wrapper class level and
put the wrapper classes in a list of some sort to keep the classes alive.
The way you're doing it I'd expect to see all of your handlers going out of
scope at some point.
In some cases it also helps to declare the COM Outlook objects as static,
although don't ever do that with objects from the CommandBars collections.
--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Professional Programming Outlook 2007.
Reminder Manager, Extended Reminders, Attachment Options.
http://www.slovaktech.com/products.htm
"tobes" wrote in message
...
In case it helps, the code is he
http://gist.github.com/12823
(It's quite long).
Tobin