Click here to Skip to main content
15,886,578 members

Comments by vikramaditya234 (Top 1 by date)

vikramaditya234 28-Jan-12 5:10am View    
"LControlKey+LControlKey" means "left control key" pressed twice.
The color of the title bar is not changing, however the event of form activated is getting called and the icon on the taskbar is blinking.
Here is how I am doing it:
1. I have one form class and another operation class. The object of the form class has been passed to the operation class.
2. The logic for implementation of shortcut key is in operation class and when the shortcut key is detected the object of form is used to activate the form.
3. Once form1.activate() is processed the event for form activated is triggered and the respective function is called from inside form class.
4. I have tried using form1.focus() from operation class and in form class both with no luck.
5. I even disabled all the controls present inside the form, but this also didnt help.

Trying all the above still gives the same output. That is, when the form is deactivated or minimized and the shortcut key is used for the 1st time, the form gets activated, with the change in the title bar. Now I take the form out of focus(deactivate or minimize) and again use shortcut key to activate the form, this time the form is not activated and the icon in the taskbar starts blinking.
The proper activation works only once, not after that.