Jump to content
Sign in to follow this  

Problem with DllCallback

Recommended Posts


... so at least i guess its due to the DLL Callback ...

I have written a small program, which is for the computer learning group of my mother.

Basically it should show a key name and the student should press the according key. If he presses the right key, the program says "correct" and asks for the next key. If he presses the wrong key, the program should display "Wrong, you pressed the key <...>" until he presses the right key.

I used a DLL Callback to catch all keys pressed.

The keys that the program asks for are only special keys like "Shift", "Alt", "Win", "Num Lock", etc.. To avoid Menus and the Start Menu popping up, i used BlockInputEx.

Sooo ... on my PC with Windows XP it works fine. On my working PC with Windows 7 Business it works also fine. On the Windows 7 Notebook of my mother it stops working after several keystrokes, just as if the DllCallback would stop reporting keys. The GUI still responds normal, i can click on Exit and it closes.

I just also discovered, that when i block the Win keys with BlockInputEx, the Win key hangs in the "down" state if pressed once (only on the Win7 of my moms notebook). But this seems not related to the program stopping to work.

Also there seems to be a problem with the program exiting suddenly, but this occurs only every now and then and is not really reproducable.

Since i know this would be a similar logic as a key logging program i will not post the script, but i will send it to anyone via PM, who might be able to help me.

Anyone has an idea? Please? My mom wants to use the program on monday, since her course starts then, so a quick reply would be very much appreciated.



Share this post

Link to post
Share on other sites

No ideas? Is my problem too special? :)

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  


Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.