Order of events: grid change vs. grid cell click

2 posts, 1 answers
  1. Boris
    Boris avatar
    24 posts
    Member since:
    Aug 2015

    Posted 10 Jun 2020 Link to this post


    I have a grid with custom template column and with event handler for grid change event (I have omitted not important parts of code):

            .Columns(columns =>
                // other columns definitions - not important here
                columns.Bound(p => p.SlaveAccount.Owneridname).Title("Vlastník")
                    .ClientTemplate("<div class='contact-presenter'>#=SlaveAccount.Owneridname#</div>");
            .Selectable(selectable => selectable.Mode(GridSelectionMode.Single))
            .Events(events => events

    I have assigned event handler for click on my custom column too:

        $('#AccountGrid').on('click', '.contact-presenter', showContactDetail);

    I want to prevent the selection of the whole row, when user clicks on my custom column. I don't know how to do it, because change event is fired before cell click event.

    Is there a way to change the order of the events?


    Thanks for help,


  2. Answer
    Tsvetomir avatar
    797 posts

    Posted 15 Jun 2020 Link to this post

    Hi Jiri,

    It is correct that at the time the click event for the custom element is triggered, the row is already selected. What I can recommend is that you immediately deselect the row:

    $('#grid').on('click', '.contact-presenter', function(e){
            var row = $(e.target).closest("tr");

    I hope this helps.


    Kind regards,
    Progress Telerik

    Progress is here for your business, like always. Read more about the measures we are taking to ensure business continuity and help fight the COVID-19 pandemic.
    Our thoughts here at Progress are with those affected by the outbreak.
Back to Top