Outlook captures the ownership of backspase and delete keys against the form of an addin

D

danleis

Hi All,

I've developped an addin in VC#.NET. I use a form with some textboxes. The
form is modeless. When I press the Backspace or Delete keys, they loose
their effects on the textbox, but they put their effects on the Outlook
Explorer underlaying my form.
It seems as if the Outlook would be snatching away the event from the
framework.

Any suggestions appreciated.

Thnx.

Danleis
 
D

danleis

Yes, thanks. I implemented the keyboardhook, it works fine. I can forward
the delete and backspace key events, but there's another problem: how to
avoid outlook to catch the same events. I mean, if the user wants to delete
something in the textbox, will delete some mails from the mailbox as well.

But my main problem is how to display a mail, using the
Outlook.MailItem.Display method, while a dialog box is also displayed. When
my dialog box is modal, outlook says to close it before displaying the mail.
If the dialog box is modeless, i face the problem described above.

So, what can i do?

Thanks
 
D

Dmitry Streblechenko

You can set the message to WM_NULL in your hook proc.
If you are displaying a dialog, why would you want to display another
window? I don't think this looks clean from the UI design point of view.

Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
 
D

danleis

Thank you for your help. It works :)

I display a dialog box with a list of messages. I show custom information
(custom properties) of a message, and the user can edit them. I wanted to
provide possibilty to view the attachments of the underlaying message. It's
easiest way, to show the message themself.

Daniel
 

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