onKeyPress event and keyboard navigation


I want to listen to a specific keypress (‘F9’ for example) and do some custom functionality on that keypress. On any other keypress I want to use the keyboard navigation function.

How can I perform that action? I’ve already attached a onKeyPress event but that seems to override the keyboard navigation functionality completely.


The following solution works well for me locally:
tree.attachEvent(“onKeyPress”, function(key, ev){
if (key==120){
alert (“f9 pressed”)
return true

If the problem still occurs for you please, provide a complete demo or share a demo link, where the problem can be reconstructed.


Can we get enableKeyboardNavigation() added to treeview please?


Unfortunately we’re not planning to add the keyboard navigation to the treeview in the near future.
I’ll send your request to the dev team and it will be checked for the possibility to add it ti the roadmap