Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

VBA Outlook contact save

Status
Not open for further replies.

dgillz

Instructor
Mar 2, 2001
10,038
US
I am trying to run some VBA when a contact is saved in outlook, but I cannot figure out how to make such an event fire.

Any ideas out there?

Software Sales, Training, Implementation and Support for Macola, eSynergy, and Crystal Reports

"What version of URGENT!!! are you using?
 
Hi dgillz

Outlook is a bit of a pain to code in but what you will have to do is to create a wrapper for Explorer & Inspector events, create a WithEvents Variable e.g. "Private WithEvents aContact As Outlook.ContactItem" and you should be able to access the events that way. By the sounds of it you might want to look at the MAPIFolder.Items.ItemChange event for the contact folder.

The other problem is that if you are doing it in VBA is that Outlook .DAT & .OTM weren't really designed to be deployed to to other users - you have to mess around with macro security to get it to load properly. You might possibly want to think about a COM addin of some sort.

A good site for advanced Outlook coding tips is
Regards

Asjeff
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top