help button and f1 key error
C#
1
Posts
1
Posters
0
Views
1
Watching
-
hi i have a question about help file button and f1 keydown property in c#. can we have in a form help button and keydown property about help(with press F1 key) ? i use the following commands for the key : ------------------------------------------- if (e.KeyCode == Keys.F1) { Help.ShowHelp(this, "Help.chm"); } and for the help button: ----------------------------- Help.ShowHelp(this, "Help.chm"); But only one of the two methods are working the other one activated when start other one method. for example if when i press F1 key is activated the help file then if i press the help button will work too but if i close the running program and i will start again and press help button without press f1 key before then the button does not working.