Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Command Bars
  New Posts New Posts RSS Feed - Using Accessibility to get "handle" of XTPToolBar
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Using Accessibility to get "handle" of XTPToolBar

 Post Reply Post Reply
Author
Message
Singlemalt View Drop Down
Newbie
Newbie


Joined: 27 July 2010
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote Singlemalt Quote  Post ReplyReply Direct Link To This Post Topic: Using Accessibility to get "handle" of XTPToolBar
    Posted: 27 July 2010 at 10:26pm
Hi, new user, currently evaluating the product.

I am trying to use the Windows API method AccessibleObjectFromWindow to retrieve the XTPToolBar "handle" from an application.

I found a related forum post here, that was unfortunately never brought to closure: http://forum.codejock.com/forum_posts.asp?TID=12815

The general method is as such, using Microsoft word as an example:

Word::Window* pWindow = NULL;
HRESULT hr = AccessibleObjectFromWindow(hwnd, OBJID_NATIVEOM, __uuidof(Word::Window), (void**)&pWindow);


To use this effectively, you need to know the correct object declaration, in this case, "Word::Window".  I understand that Codejock provides access to the objects via this Windows API, however I can not find documentation for which object to use here.

I assume it is something like "CXTPToolBar::xyz".  Does anyone know what xyz needs to be here?  Maybe point me to the correct documentation?  Even better, anyone have a code fragment they would be so kind to share?


Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 28 July 2010 at 4:58am
You use MFC version ? Then why you just can't take pToolBar->m_hWnd ?
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
Singlemalt View Drop Down
Newbie
Newbie


Joined: 27 July 2010
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote Singlemalt Quote  Post ReplyReply Direct Link To This Post Posted: 28 July 2010 at 6:49am
Hi Oleg, thanks for responding.  The question is the same as in the other thread I linked to.  Reading back, I guess I forgot to mention that , sorry.  The objective is to get the menu handle from another application that uses your toolkit.

In that other thread, you said: "You have call AccessibleObjectFromWindow for Menu window - see it in Spy++ - its window with XTPToolBar class."  Spy++ does indeed show the class of the menu I am targeting is "XTPToolBar".  However, in that other thread, the parameters for the call to AccessibleObjectFromWindow were not detailed, and in fact, I can not locate those details in the documentation.

Thanks.
Back to Top
Singlemalt View Drop Down
Newbie
Newbie


Joined: 27 July 2010
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote Singlemalt Quote  Post ReplyReply Direct Link To This Post Posted: 29 July 2010 at 11:29pm
No way to do this then, I guess?

Bummer.
Back to Top
Singlemalt View Drop Down
Newbie
Newbie


Joined: 27 July 2010
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote Singlemalt Quote  Post ReplyReply Direct Link To This Post Posted: 02 August 2010 at 9:18pm
Bumping in case there is a solution.
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.139 seconds.