View Single Post
  #9  
Old October 2nd 06, 04:51 PM posted to microsoft.public.outlook.program_vba
Ken Slovak - [MVP - Outlook]
external usenet poster
 
Posts: 5,848
Default ContactItem.Save()

Can't you re-add your event handlers using the += syntax when you are
finished with your synch? Are the flags you're now using not working? If
they are just keep using them.

I'd probably not remove the event handlers but simply set a flag that says
an update/move operation is in progress. If that flag is set then just exit
the OnChange event without doing anything.

If you remove the birthday setting by setting the date to None (1/1/4501) no
reminder will be created and no recurring appointment for that birthday will
be created. The same will apply to Anniversary. After the move you can then
re-set the birthday/anniversary property as needed from your stored values
and then handle the creation of the recurring appointments.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003
Reminder Manager, Extended Reminders, Attachment Options
http://www.slovaktech.com/products.htm


"Virda" wrote in message
...

Thanks a lot Ken Slovak,

Now the sync problem has removed the instantiate and uninstantiation logic
of classes worked. But I didn't make the collecion.

Now the problem is all my classes related to conact/task/calendar/ are
instantiated in Application_start() of Addin.

Wo, whenever I receive Contact add event I made changes to it and call
ContactItem.Save(). by doing this the item_change event is raising

If I unregister the event using

items.ItemChange -= new Outlook.ItemsEvents_ItemChangeEventHandler(Func);

then this event perminently removed.

How could I overcome this problem, for the time being I used bool
variables
tok handle this situation.

Also, Another problem is whenever birthday field set in contact item.
the new activity added in calendar I want to remove this activity or it
should not be added to calendar folder.

If I try to remove it inside Contact item add evet, then at that time this
activity not cteated.

Thanks a lot again your kind cooperation and on time answers.


Ads