Kendo Grid Showing Network activity

The datasource has a start and end event associated with it.
These can be used to give a visual indication of activity.

As part of the datasource changing you can add

dataSource => dataSource  
.Events(e => e.RequestStart("datasourceRequestStart").RequestEnd("datasourceRequestEnd"))

The e.type gives the name of the action being carried out.
Example handlers are

function datasourceRequestStart(e) {  
    if(e.type === "update"){
        $("#syncmessage").html("Saving").show();
    }else{
        $("#syncmessage").html("Reading").show();
    }
}
function datasourceRequestEnd(e) {  
    $("#syncmessage").html("").hide();
}

Where

<div class="CBinformationLeft" style="width:100px" id="syncmessage"></div>  

References:
http://docs.telerik.com/kendo-ui/api/javascript/data/datasource#events-requestStart


Above referring to version
Telerik Kendo UI Professional Q1 2015
Telerik UI for ASP.NET MVC Q1 2015


comments powered by Disqus