Description: Hooks are one of the most powerful features of Windows. We can hooks to trp all the events in the Windows environment. This example shows how to trap keyboard events and save the keys to a text file.
In the Microsoft® Windows™ operating system, a hook is a mechanism by which a function can intercept events (messages, mouse actions, keystrokes) before they reach an application. The function can act on events and, in some cases, modify or discard them. Functions that receive events are called filter functions and are classified according to the type of event they intercept. For example, a filter function might want to receive all keyboard or mouse events. For Windows to call a filter function, the filter function must be installed — that is, attached to a Windows hook (for example, to a keyboard hook). Attaching one or more filter functions to a hook is known as setting a hook. If a hook has more than one filter function attached, Windows maintains a chain of filter functions. The most recently installed function is at the beginning of the chain, and the least recently installed function is at the end...
Resource Specification
Date Added:
01/31/2004
tr>
Last Updated:
01/31/2004
Author:
H. Joseph
Average Visitor Rating:4.71 (out of 5) Number of Ratings: 14 Votes
Tutorial Maniacs - C#, PHP, ASP, .NET, Photoshop, Flash, Fireworks, & other design and programming tutorials... The most comprehensive collection of QUALITY hand picked design and programming tutorials and articles...(C) 2003