Hello,
I'm trying to assign shortcuts keys in my program. The only solution i found is to create a menu item and set its shortcut key property... Problem is that it is just not right... i dont need a menu... so why create one for just a shortcut...
Using the keys events is also not useful because i need the shortuct to be active for each of my controls in the form...
The best idea i had is to create a key logger that will catch all keys pressed in the OS and check if the form is in foucs, but i rather evoid that...
Any ideas? (Using .Net 2 Only)
Thanks!!!
Guest UserPosted Dec 17, 2008, 5:01 PM
nir malbinPosted Dec 17, 2008, 4:25 PM
The idea of creating an object that his purpose is to be a menu and use it for a shortcut... its ugly.
I thought about something nice. I'll write a class that takes a control and signs up to all of his controls keys events...
This is the best idea so far...
Guest UserPosted Dec 16, 2008, 3:44 PM
Why not use a menu to set up your shortcut keys and their events, and then set the Visible property of the menu control to False?