Old 06-16-2014, 03:15 PM   #1
Lawrence
Human being with feelings
 
Join Date: Mar 2007
Posts: 21,551
Default Windows Help

... for rookies.

Can you Windows developer guys tell me how to use the SetWindowsHook API (or similar) to hook into an external app message? Specifically, I'm inserting custom menus into an external app and I need to trap the message (WM_SYSCOMMAND I think, case the ID of that menu item and act) being generated when that menu is clicked, to act on it from the add on tool.

So the add on tool inserts a new menu into the external app (that part I've figured out) but also needs to act on the mouse click event of the custom menu.

If anyone could help me figure this out, thanks in advance. My googling on this led to a few avenues I've investigated but nothing that bore fruit.
Lawrence is offline   Reply With Quote
Old 06-16-2014, 04:05 PM   #2
karbomusic
Human being with feelings
 
karbomusic's Avatar
 
Join Date: May 2009
Posts: 29,260
Default

Quote:
Originally Posted by Lawrence View Post
... for rookies.

Can you Windows developer guys tell me how to use the SetWindowsHook API (or similar) to hook into an external app message? Specifically, I'm inserting custom menus into an external app and I need to trap the message (WM_SYSCOMMAND I think, case the ID of that menu item and act) being generated when that menu is clicked, to act on it from the add on tool.

So the add on tool inserts a new menu into the external app (that part I've figured out) but also needs to act on the mouse click event of the custom menu.

If anyone could help me figure this out, thanks in advance. My googling on this led to a few avenues I've investigated but nothing that bore fruit.
LOL so that answers one of my questions
__________________
Music is what feelings sound like.
karbomusic is offline   Reply With Quote
Old 06-16-2014, 04:35 PM   #3
Lawrence
Human being with feelings
 
Join Date: Mar 2007
Posts: 21,551
Default

Yeah, it's been a bit of a rabbit hole so far. All of the examples I try to learn from use keyboard and mouse hooks and from what I can gather, the menu hook would need a MessageFilter hook or something that I can't get setup correctly.
Lawrence is offline   Reply With Quote
Reply

Thread Tools
Display Modes

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

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

Forum Jump


All times are GMT -7. The time now is 01:02 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.