Click here to Skip to main content
15,880,725 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
What I want to do:

I'm sending to an external application a mouse down signal (for left or right button). And when in the result of this action application shows some kind of menu (application menu or context menu) I need to:

- detect the fact that menu was created;
- get screenshot|image of this menu (or get its items list);
- hide the menu (or if it's possible not to show it in a first place and just get screenshot/items list);
- *here I will show to user a representation of the menu inside of my application and user will choose some action*;
- send the results of users action back to the application.

How can I do something like this?

I've tried to get context menu HWND handle by calling FindWindowEx() with desktop as a parent handle and class "#32768". Like described here https://stackoverflow.com/questions/12411782/accessing-a-right-click-context-menu-from-an-external-application. But I'm always getting null as a result.

But it's only a partial solution of one of the stated problems anyway so I would be grateful if you have ideas about alternative approaches.
Posted
Updated 25-Jun-15 12:03pm
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900