OnButtonClick event in MSOutlook called twice.

  • Thread starter KarthikonIT via OfficeKB.com
  • Start date
K

KarthikonIT via OfficeKB.com

Hi,
I m Creating a Plugin for MS OUtlook, I a few questions

Q. I have added Button to New email window(ie. the window that
is opened when an email is double clicked)

Brief description of my architecutre:
I have a class called "INspector wrapper" which implements the "Outlook::
InspectorEvents"
for every new email a new Instance of this class will be created.


I have a class called "BtnWrapper" which implments the "Office::
_CommandBarButtonEvents"
for every button created a new Instance of this class will be created.

DispEventAdvise & DispEventUnadvise are added in the constructor and
destructor of "BtnWrapper"& "INspector wrapper" class for resp. events.



Instance of the "BtnWrapper" class will be created with "INspector wrapper"
class.

Now my problem is when 2 emails are double clicked and opened in new window.
"OnButtonClick" event is called twice.




Note:
when n mails are double clicked & opened. "OnButtonClick" triggered n times.
Buttons is added only once in the toolbar.



Any clue to resolve this.

Thanks in Advance.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top