AllowSubmitOnEnter Not Working

4 posts, 0 answers
  1. Donna
    Donna avatar
    4 posts
    Member since:
    Jun 2010

    Posted 01 Sep 2017 Link to this post

    I'm having some trouble getting the AllowSubmitOnEnter property to work.  I have a page with two grids...selecting a row in Grid A populates Grid B.  In both grids, my users want to be able to use the enter key to submit inserts/edits on the grid.  

     

    I have set the following navigation settings on both grids:

     <ClientSettings  AllowKeyboardNavigation="true"   >
               <KeyboardNavigationSettings AllowSubmitOnEnter="true"  />
     </ClientSettings>

     

    On Grid A, this works perfectly and the users can press enter.  However, on Grid B, those settings seem to be getting ignored.  When the users press enter to submit an insert/edit, those events are not fired.  Instead, the submit button's event is fired.  

    Can anyone give me a clue as to what to look for?  The grids are pretty identical in properties, the biggest difference being that Grid A populates Grid B.  I'm confused as to why the exact same properties seem to work on one but are ignored on the other.

    Thank you!
    Donna

  2. Donna
    Donna avatar
    4 posts
    Member since:
    Jun 2010

    Posted 01 Sep 2017 in reply to Donna Link to this post

    I should add that I'm using version 2017.2.621.35
  3. Donna
    Donna avatar
    4 posts
    Member since:
    Jun 2010

    Posted 01 Sep 2017 Link to this post

    After several hours of playing with this, stripping out updatepanels, etc, I've come to the conclusion that the AllowSubmitOnEnter just doesn't work for more than one grid on a page.  My guess is that having more than one somehow causes a conflict.  I even removed my submit button, but in that case, the second grid, upon Enter, would just fire the command on the first grid to put it into Insert mode.  The second grid never fired the appropriate Update/Insert command. 

     

    For now, I've gotten around this by just catching and disabling the Enter key, so my users have to use their mouse.  It's not ideal, but it prevents accidental submission of the form.

    I would like some confirmation from Telerik, if possible, that I'm on the right track.  Is it true that the AllowSubmitOnEnter won't work for more than one grid on a page?  Or am I completely missing something here?

    Thank you!

    Donna

  4. Eyup
    Admin
    Eyup avatar
    3841 posts

    Posted 06 Sep 2017 Link to this post

    Hi Donna,

    You can try placing a hidden button on the page:
    http://www.telerik.com/forums/radgrid-disable-enter-key#KAn1O5APR0SaXfk3MrhL9Q

    Regards,
    Eyup
    Progress Telerik
    Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Back to Top