How to catch popup template save button click

2 posts, 0 answers
  1. Ed
    Ed avatar
    43 posts
    Member since:
    Dec 2019

    Posted 06 Feb 2020 Link to this post

    Is there a way to catch the click event for this and the cancel button?

    Thanks … Ed


  2. Nikolay
    Nikolay  avatar
    301 posts

    Posted 11 Feb 2020 Link to this post

    Hi Ed,

    I would suggest subscribing to Save and Cancel events of the grid that are fired upon click on Update button and Cancel button respectively. This could be done like below.

    - Register the events:

        .Columns(columns =>
            columns.Bound(p => p.ProductName);
            columns.Bound(p => p.Discontinued).Width(120);
            columns.Command(command => { command.Edit(); command.Destroy(); }).Width(250);
        .Editable(editable => editable.Mode(GridEditMode.PopUp))
        .Events(e => e.Save("onSave").Cancel("onCancel"))

    - Declare the event handlers:

            function onSave(e) {
            function onCancel(e) {

    Additionally, I am sharing a forum thread discussing how to catch the event of the update button. I hope this would be helpful to you:

    Let me know if you have any questions.

    Progress Telerik

    Get quickly onboarded and successful with Telerik UI for ASP.NET Core with the dedicated Virtual Classroom technical training, available to all active customers.
Back to Top