How to get Inspector object from Window handle

  • Thread starter Thread starter Tom
  • Start date Start date
T

Tom

Hi,

I post this question on Outlook-General and administrator suggest me putting
here.

I am able to get any window handle from outlook. For each of these window
handle I've tried AccessibleObjectFromWindow( hWnd, (DWORD)OBJID_NATIVEOM,
IID_IDispatch, (void**)&pDispWindow); I am able to get Word.Document object
from a window class as "_WwG". But I am not able to get Outlook.Inspedtor
object from any of these window.

Is there any way to get Outlook.Inspedtor object from one of these window?

Thanks in advance.

Tom
 
You can how the other way around? For a given window handle, find its
topmost parent, then compare that handle with all the window handles for
each inspector in the Application.Inspectors collection (use IOleWindows for
each inspector).

--
Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
-
 
Thanks Dmity, finally I am able to find a way to get Inspector object.
Because there is only ONE Outlook running in one system. I am able to get
Outlook Application object without window handle. From Application object I
have no problem doing anything as same in VBA.

Tom
 
Back
Top