Call to Kendo Grid in Then of Promise fails

2 posts, 0 answers
  1. Beryl
    Beryl avatar
    22 posts
    Member since:
    Jul 2015

    Posted 11 Aug 2017 Link to this post

    I am using Kendo Grid with Angular.  I need to call the grid only after the return of a promise.  However, placing a call to the grid in the "THEN" causes the grid to never load.  Even if I make a direct call to;  it will not read the datasource.


    Here is my code:


      function initialize() {
          var savedSearchCriteria;
          var promise = isFiltered();
          promise.then(function() {
              savedSearchCriteria = $window.localStorage.getItem('pecGeneralSearchCriteria');
          }).then(function () {

    A call to searchGrid() outside of the "THEN" for the promise works fine.

  2. Alex Hajigeorgieva
    Alex Hajigeorgieva avatar
    1082 posts

    Posted 15 Aug 2017 Link to this post

    Hello Beryl,

    I would need some more of the code in the application to get a good idea why you are unable to get the Kendo UI Grid reference in the promise.

    Here is an article which shows how to get widget references in an AngularJS application. Could you share the searchGrid() function as well as the grid configuration and the HTML element from which it is initialized?

    Look forward to hearing back from you.

    Alex Hajigeorgieva
    Progress Telerik
    Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Back to Top