JSF: How to bind a CommandButton functionaity to an ENTER or ESCAPE key?
Hello!
I use a JSF in my application. There are a lot of JSF Create - , Edit - and Delete - pages. All of this pages have to Command buttons:
OK - which performs the action
Cancel - which cancels the action.
So, the problem is that it's necessary to bind an OK button action to an ENTER key and a Cancel button action to an ESCAPE key. The AccessKey property doesn't suite for this case, because it allows to work with literal keys only.
Could anybody help me to solve a problem?
Thanks in advance.