New to Kendo UI for jQueryStart a free 30-day trial

Read

methods

Reads data items from a remote/custom transport (if the transport option is set) or from a JavaScript array (if the data option is set).

The read method always makes a request to the remote service unless the Data Source is offline.

Returns:Promise

—A promise that will be resolved when the data has been loaded or rejected if an HTTP error occurs.

<script>
var dataSource = new kendo.data.DataSource({
  transport: {
    read: {
        url: "https://demos.telerik.com/service/v2/core/products"
    }
  },
  change: function(e) {
    var view = this.view();
/* The result can be observed in the DevTools(F12) console of the browser. */
    console.log(view[0].ProductName); // displays "Chai"
  }
});

var optionalData = { foo: 42, bar: "baz" };

dataSource.read(optionalData);
</script>
<script>
var dataSource = new kendo.data.DataSource({
  transport: {
    read: {
        url: "https://demos.telerik.com/service/v2/core/products"
    }
  }
});
dataSource.read().then(function() {
  var view = dataSource.view();
/* The result can be observed in the DevTools(F12) console of the browser. */
  console.log(view[0].ProductName); // displays "Chai"
});
</script>
Not finding the help you need?
Contact Support