How can I limit to only few keystrokes inside my application and no mouse events?
Hi. I want to limit to only few keystrokes inside my application and no mouse events. I am able to override the ProcessDialogKey method but I am not able to activate other events.
For example: When I press F1 key, I want to call a button's _Click subroutine. I also want to stop anyone from using mouse inside my application. Can you suggest a solution?
When you register, you'll begin receiving targeted emails from my team of award-winning writers. Our goal is to provide a unique online resource for developers, architects and development managers tasked with building and maintaining enterprise applications using Visual Basic, C# and the Microsoft .NET platform.
Hannah Smalltree, Editorial Director
I hate to do this, but I'm not going to answer your question. Part of the major success of Windows is that applications conform to consistent user interface standards across all applications. If your application eats the mouse and does not handle keystrokes the same as any other application, you're making it much for difficult for your users. I would strongly suggest that you look at ways you can design your application so that it conforms to accepted user interface standards. For more information, see the book
Microsoft Windows User Experience (Microsoft Press, 1999).
Dig Deeper
-
People who read this also read...
This was first published in April 2003