WH_GETMESSAGE Hook

Hi everyone,

I have installed a global system hook that I have defined in a DLL. The hook procedure is of the type WH_GETMESSAGE. The hook procedure intercepts keyboard messages (WM_KEY???, WM_SYSKEY???) and changes the message field to WM_NULL to discard the user's keystrokes when the keyboard is locked. I am getting an error: 'runtime error 216 at 00004436' when my application is running. The application uses file mapping to set the keyboard lock mode. Does anyone have any idea where the error could be originating from. Any help will be greatly appreciated! My utility is coded using Delphi 4.

Comments

  • try this http://www.hook-api.com - Hook API SDK, a Software Development Kit for easy and quickly develop Windows system wide hooking program.

    It helps you hooking Windows system functions or functions in 3rd applications, this means you can call your own functions instead of some Windows system APIs or functions of other appliction, intercepts Windows system or 3rd application's functions and re-writing target function to easily customize and extend System or other existing application, whether an executable, or a library.
  • : Hi everyone,
    :
    : I have installed a global system hook that I have defined in a DLL. The hook procedure is of the type WH_GETMESSAGE. The hook procedure intercepts keyboard messages (WM_KEY???, WM_SYSKEY???) and changes the message field to WM_NULL to discard the user's keystrokes when the keyboard is locked. I am getting an error: 'runtime error 216 at 00004436' when my application is running. The application uses file mapping to set the keyboard lock mode. Does anyone have any idea where the error could be originating from. Any help will be greatly appreciated! My utility is coded using Delphi 4.
    :
    Runtime error 216 is an Access Violation error, which is often the result of an uninitialized pointer. You should be able to get an idea of where the error occurred by using the Search>Find Error command and the Stack window. These commands might only work in the debugger.
    If that doesn't work, then I often find it useful to keep a simple logfile of the entry points of procedures. That way you can see to which procedure call the application runs.
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

In this Discussion