In .NET is it possible to use a key other than F1 with the HelpProvider component?

It is possible to use a key other than F1 with the HelpProvider component? Or a combination of keys other than F1?  Thank you!
MEINMELAsked:
Who is Participating?
 
that_it_guyCommented:
Not sure, but check out this link. Maybe it will help?

http://www.west-wind.com/WebLog/posts/1438.aspx
0
 
spprivateCommented:
You want a help key association for the application you create or for your Visual Studio editor
0
 
MEINMELAuthor Commented:
This would be for an application.  I want to use the F1 key for something else and Alt-F1 for the HelpProvider component. I am working in VB .NET.
0
Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
MEINMELAuthor Commented:
I really need an answer to this as quickly as possible.  If the answer is that I need 'a help key association', how do I set that up?  Thank you
0
 
that_it_guyCommented:
You have to provide code in the key handler event to use other keys. For example:

Private Sub txtName_KeyDown(ByVal sender As Object, _
ByVal e As System.Windows.Forms.KeyEventArgs) _
Handles txtName.KeyDown
    If e.KeyCode = Keys.F1 And e.Alt Then
    Help.ShowPopup(txtName, "This is an alternative help message", _
    New Point(Me.Location.X + txtName.Location.X, _
    Me.Location.Y + txtName.Location.Y))
    End If
End Sub

This would show help if the Alt+F1 was pressed.
0
 
MEINMELAuthor Commented:
Thank you for your resonse!  Is it possible to create a wrapper class around the HelpProvider and intercept the F1 key?
0
 
MEINMELAuthor Commented:
Thank you!  If anyone has done this I would appreciate some input on how well it worked and if there were any negatives to doing this.
0
 
MEINMELAuthor Commented:
The solution was acceptable, but I would also like to have known if an Expert has done this before and if there were any problems.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.