-
8 Apr 2011 7:32 AM #1
Form submit on Enter
Form submit on Enter
I'm terribly ashame to ask such a frequent question, but I have searched for the solution and none works. So the question is obvious: how do I submit my form on Enter key? Yes, in ExtJS4b2.

-
13 Apr 2011 4:49 AM #2
I'm also trying to figure this out
-
13 Apr 2011 8:32 AM #3
vg Steffen
--------------------------------------
Release Manager of TYPO3 4.5
energlobe.de - german online magazine
-
13 Apr 2011 11:02 AM #4
This is something that has never been built-in. In the past I've set a listener on the special key event for textfields. You could easily create a FormPanel subclass that did this for you.
PHP Code:xtype: 'text',
fieldLabel: 'Field 2',
name: 'field2',
listeners: {
specialkey: function(field, e){
// e.HOME, e.END, e.PAGE_UP, e.PAGE_DOWN,
// e.TAB, e.ESC, arrow keys: e.LEFT, e.RIGHT, e.UP, e.DOWN
if (e.getKey() == e.ENTER) {
var form = field.up('form').getForm();
form.submit();
}
}
}
Similar Threads
-
Ajax Form Submit with Enter Key
By lenzenc in forum Ext 2.x: Help & DiscussionReplies: 17Last Post: 14 Sep 2010, 7:13 AM -
Submit Form with Enter
By drieraf in forum Ext 2.x: Help & DiscussionReplies: 14Last Post: 28 Apr 2010, 4:19 AM -
How to submit a form using the enter key?could anybody please help
By misra123 in forum Ext 2.x: Help & DiscussionReplies: 4Last Post: 2 Sep 2008, 1:10 AM -
i want Enter key submit my form
By mnask in forum Ext 2.x: Help & DiscussionReplies: 10Last Post: 3 Jul 2008, 1:03 AM -
Form without submit button, handling submit with shift+enter...
By violinista in forum Ext 1.x: Help & DiscussionReplies: 4Last Post: 5 Jun 2007, 12:02 AM


Reply With Quote