Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. AaaAAaAARRrRRgGgHHH!!!! KERNEL32.DLL ERROR!!

AaaAAaAARRrRRgGgHHH!!!! KERNEL32.DLL ERROR!!

Scheduled Pinned Locked Moved C / C++ / MFC
helpquestion
4 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Offline
    R Offline
    Rickard Andersson20
    wrote on last edited by
    #1

    I have keyboard hook installed in my app, when my parent window is visible it works just fine to press the specific key that do something, but when I press the Hide button in my parent window to hide the parent window and then try to press the same key it KERNEL32.DLL crash! I have two keys that are "hooked"... one of them works but not the other. That one that works is to sjow the parent window... hm.. confusing isn't it? Kernel32 isn't that the file that has to do with the user inputs? so, is it my CALLBACK for the keyboard hook? ------------------------------ ©0d3 ©®4©k3® - That's me! :) ------------------------------

    R S 2 Replies Last reply
    0
    • R Rickard Andersson20

      I have keyboard hook installed in my app, when my parent window is visible it works just fine to press the specific key that do something, but when I press the Hide button in my parent window to hide the parent window and then try to press the same key it KERNEL32.DLL crash! I have two keys that are "hooked"... one of them works but not the other. That one that works is to sjow the parent window... hm.. confusing isn't it? Kernel32 isn't that the file that has to do with the user inputs? so, is it my CALLBACK for the keyboard hook? ------------------------------ ©0d3 ©®4©k3® - That's me! :) ------------------------------

      R Offline
      R Offline
      Rickard Andersson20
      wrote on last edited by
      #2

      I've found something interesting! When the app is visible and has FOCUS it works fine with both keys, but when it's no FOCUS.. it crashes!! hmmm ------------------------------ ©0d3 ©®4©k3® - That's me! :) ------------------------------

      1 Reply Last reply
      0
      • R Rickard Andersson20

        I have keyboard hook installed in my app, when my parent window is visible it works just fine to press the specific key that do something, but when I press the Hide button in my parent window to hide the parent window and then try to press the same key it KERNEL32.DLL crash! I have two keys that are "hooked"... one of them works but not the other. That one that works is to sjow the parent window... hm.. confusing isn't it? Kernel32 isn't that the file that has to do with the user inputs? so, is it my CALLBACK for the keyboard hook? ------------------------------ ©0d3 ©®4©k3® - That's me! :) ------------------------------

        S Offline
        S Offline
        squizz
        wrote on last edited by
        #3

        where is your callback declared ? I assume that it is located in your program. to make a global hook, the callback must be placed in a dll.

        R 1 Reply Last reply
        0
        • S squizz

          where is your callback declared ? I assume that it is located in your program. to make a global hook, the callback must be placed in a dll.

          R Offline
          R Offline
          Rickard Andersson20
          wrote on last edited by
          #4

          You got it! I've just tried it and now it works!! THANKS! ------------------------------ ©0d3 ©®4©k3® - That's me! :) ------------------------------

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups