Disable hotkeys

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hello haw I disable the hotkeys in Excel 2002 or customize it.

Thanks a lot.
 
You could use a small macro.

For example, this disables the F1 (help) key:

Option Explicit
Sub disableF1()
Application.OnKey "{f1}", ""
End Sub

And this would toggle it back to normal.

Sub enableF1()
Application.OnKey "{f1}"
End Sub

If you look at sendkeys in VBA's help, you'll see how to override special keys.
(Like ctrl-c for copy.)
 
Thanks a lot.

Dave Peterson said:
You could use a small macro.

For example, this disables the F1 (help) key:

Option Explicit
Sub disableF1()
Application.OnKey "{f1}", ""
End Sub

And this would toggle it back to normal.

Sub enableF1()
Application.OnKey "{f1}"
End Sub

If you look at sendkeys in VBA's help, you'll see how to override special keys.
(Like ctrl-c for copy.)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top