PC Review Forums Newsgroups Microsoft Outlook Microsoft Outlook Third-Party Utilities Select an e-mail item

Reply

Select an e-mail item

 
Thread Tools Rate Thread
Old 22-08-2003, 12:54 PM   #1
Alex Ionescu
Guest
 
Posts: n/a
Default Select an e-mail item


Hi,

I would like to know if it's possible to select an e-mail item with the
Outlook API (or Windows API).
I'm looking for EITHER one of the following:
- Select an item based on mouse position
- Select an item when right-clicked, without showing the context menu
- Select an item when control+right clicked.

Right now I have some code that shows my menu:

If wMsg = WM_RBUTTONDOWN Then
If wParam = (MK_CONTROL Or MK_RBUTTON) Then
GetCursorPos MousePos
XPMenu.ShowMenu MousePos.x, MousePos.y
Exit Function
End If
End If

XPMenu being a class that I created for the owner-drawn menu. The problem is
that since I exit the function, two things happen:
1) The outlook context menu doesn't show (GOOD, I want this)
2) The item doesn't get selected (BAD, my menu items can't react to the
currently selected item)

So I'd like to force a way for outlook to select the item...I've tried mouse
events, but they end up showing the context menu.

Best regards,
Alex Ionescu


  Reply With Quote
Old 25-08-2003, 11:33 PM   #2
Dmitry Streblechenko
Guest
 
Posts: n/a
Default Re: Select an e-mail item

No, you cannot select an Outlook item programmatically.

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


"Alex Ionescu" <ionucu@dontspammevideotron.ca> wrote in message
news:%23Mf0oPKaDHA.3360@tk2msftngp13.phx.gbl...
> Hi,
>
> I would like to know if it's possible to select an e-mail item with the
> Outlook API (or Windows API).
> I'm looking for EITHER one of the following:
> - Select an item based on mouse position
> - Select an item when right-clicked, without showing the context menu
> - Select an item when control+right clicked.
>
> Right now I have some code that shows my menu:
>
> If wMsg = WM_RBUTTONDOWN Then
> If wParam = (MK_CONTROL Or MK_RBUTTON) Then
> GetCursorPos MousePos
> XPMenu.ShowMenu MousePos.x, MousePos.y
> Exit Function
> End If
> End If
>
> XPMenu being a class that I created for the owner-drawn menu. The problem

is
> that since I exit the function, two things happen:
> 1) The outlook context menu doesn't show (GOOD, I want this)
> 2) The item doesn't get selected (BAD, my menu items can't react to the
> currently selected item)
>
> So I'd like to force a way for outlook to select the item...I've tried

mouse
> events, but they end up showing the context menu.
>
> Best regards,
> Alex Ionescu
>
>



  Reply With Quote
Reply



Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off