Kaushik Lingerkar
Kaushik Lingerkar

Reputation: 449

Do something after a row is added in kendo grid

Is there a equivalent event for add row similar to the remove event in kendo grid. Edit event doesn't seem to be helpful as it fires before the add confirmation.

Upvotes: 0

Views: 422

Answers (1)

GeorgeB
GeorgeB

Reputation: 848

You could use the RequestEnd and/or RequestStart events on the datasource:

.Events(events => events.RequestEnd("requestEnd").RequestStart("requestStart"))

Then in the function, check the type:

    function requestEnd(e) {
    if (e.type == "update" || e.type == "create") {
        doStuff();
    }
}

function requestStart(e) {
    if (e.type == "add") {
        doStuff();
    }
}

Upvotes: 3

Related Questions