Solved

How to Captur a "Hot key" (F8 for example) ?

Posted on 2011-02-12
4
449 Views
Last Modified: 2012-06-27
I would like to wite down a program which captures F8 (F8 is just an example).
whenever the user presses F8, I would like my program to "Jump".

zmau
0
Comment
Question by:zmau
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 86

Expert Comment

by:Mike Tomlinson
ID: 34879048
Hi zmau,

What LANGUAGE and VERSION are you working in here?....
0
 
LVL 66

Expert Comment

by:johnb6767
ID: 34884267
Hotkey Detective 2: Download It Here
http://www.pcmag.com/article2/0,1759,944583,00.asp

excerpt....

Hotkey Detective 2 fills this gap by showing you a list of all the hotkeys defined on your system. Duplicate hotkey assignments are displayed in red. To change a hotkey, simply select it in the list and click the Change key button. Click Locate in Explorer to make other changes to the shortcut, or remove it entirely. The program also lets you print out a list of your hotkey assignments.

Never used it personally, but have seen it online on more than one occassion....

ShortcutKey 2.2
http://download.cnet.com/ShortcutKey/3000-2346_4-10782313.html
0
 
LVL 1

Author Comment

by:zmau
ID: 34885693
Thanks all

Idle_Mind,
I am using VC 6, the language is C++, the OS is XP.

johnb6767
"ShortcutKey 2.2" and "Hotkey Detective 2", sounds like an answers to a previous questions........
http://www.experts-exchange.com/OS/Microsoft_Operating_Systems/Windows/Q_26801500.html
http://www.experts-exchange.com/OS/Microsoft_Operating_Systems/Windows/Q_26801499.html
Can you put your answer there so I can give you the score ?

I'll try them (Curiosity killed the cat).
Do you have any idea "how do they work" ?

Still, I want to know how do I do it in a software which I am installing to other people on other computres.....

zmau
0
 
LVL 86

Accepted Solution

by:
Mike Tomlinson earned 500 total points
ID: 34885705
Alrighty, I'm not a C++ developer, but look into use the RegisterHotKey() API:
http://msdn.microsoft.com/en-us/library/ms646309(VS.85).aspx

*Be aware, though, that if another application has already claimed your desired hot-key combo then you cannot also register it.  In that case, you would either have to poll the keyboard state with the GetAsyncKeyState() API (via a Timer...not the preferred method), or intercept ALL keystrokes in the same using a low level keyboard hook and WH_KEYBOARD_LL.
0

Featured Post

What Is Transaction Monitoring and who needs it?

Synthetic Transaction Monitoring that you need for the day to day, which ensures your business website keeps running optimally, and that there is no downtime to impact your customer experience.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Ever visit a website where you spotted a really cool looking Font, yet couldn't figure out which font family it belonged to, or how to get a copy of it for your own use? This article explains the process of doing exactly that, as well as showing how…
Sometimes clients can lose connectivity with the Lotus Notes Domino Server, but there's not always an obvious answer as to why it happens.   Read this article to follow one of the first experiences I had with Lotus Notes on a client's machine, my…
This Micro Tutorial will give you a basic overview of Windows DVD Burner through its features and interface. This will be demonstrated using Windows 7 operating system.
In this video, viewers are given an introduction to using the Windows 10 Snipping Tool, how to quickly locate it when it's needed and also how make it always available with a single click of a mouse button, by pinning it to the Desktop Task Bar. Int…

696 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question