This is a migrated thread and some comments may be shown as answers.

Enter Key Behavior

1 Answer 132 Views
Wizard
This is a migrated thread and some comments may be shown as answers.
Kevin
Top achievements
Rank 1
Kevin asked on 23 Feb 2016, 12:51 AM

I have a radwizard with 2 steps.  The first step has a couple of custom controls as well as some other text input fields.  The issue that I am seeing (in chrome and firefox) is when I select one of the text fields and hit enter, the wizard is firing a click event for one of the buttons on the custom controls.  What I would like to see is hitting enter fires the next button clicking event.  I thought that this is the default behavior of the radwizard.  Is there something that I may have set up improperly?  Or could I possibly set it programmatically to fire the next button click when enter is pressed?  Something like this?:

 

$(document).ready(function () {
        $("form").bind("keypress", function (e) {
            if (e.keyCode == 13) {
                $('RadwizardNextButton').click();
            }
        });
    });

 

Thanks for any help.

1 Answer, 1 is accepted

Sort by
0
Peter Filipov
Telerik team
answered on 25 Feb 2016, 10:00 AM
Hi Kevin,

You should use the client side api of the control. The get/set active index should do the trick for your case. Please review the following documentation for more details.

Regards,
Peter Filipov
Telerik
Tags
Wizard
Asked by
Kevin
Top achievements
Rank 1
Answers by
Peter Filipov
Telerik team
Share this question
or