PivotGrid with flat dynamic objects

4 posts, 0 answers
  1. Maxim
    Maxim avatar
    16 posts
    Member since:
    Jun 2008

    Posted 22 Jun 2016 Link to this post



    We have list of flat POJO objects, where objects are dynamic, we don’t know their list of fields/properties at design time. In Silverlight version of telerik Pivot grid we were able to populate list of fields and provide list of objects so that users can create columns, rows and measures at run time.Is this approach feasible with Kendo UI Pivot? Or do we have to define model and cube with dimensions and measures in advance? An example would be very useful.


    Thank you, Sergey

  2. Georgi Krustev
    Georgi Krustev avatar
    3747 posts

    Posted 24 Jun 2016 Link to this post

    Hello Sergey,

    In general, you can build the dimensions collection of the DataSource dynamically using the fields of the POJO instance. Here is a Dojo demo that demonstrates how this could be done: Please note that this is a custom approach and it is up to the developer responsible for the feature to handle it accordingly.

    Georgi Krustev
    Get started with Kendo UI in days. Online training courses help you quickly implement components into your apps.
  3. Maxim
    Maxim avatar
    16 posts
    Member since:
    Jun 2008

    Posted 28 Jun 2016 in reply to Georgi Krustev Link to this post

    Hello Georgi,

    Thank you, it is what I was looking for. However, setDataSource() only works for me once. I'm not able to update data source and I need to change number of records on demand. For an example, try to add button and call this function in your Dojo:

        var that = this;
        var getProducts = function () {
            $.getJSON("http://demos.telerik.com/kendo-ui/service/Northwind.svc/Products?$format=json", function (data) {
                var source = that.buildDataSource(data.d);

    Thanks again,


  4. Maxim
    Maxim avatar
    16 posts
    Member since:
    Jun 2008

    Posted 29 Jun 2016 in reply to Maxim Link to this post

    Hi Georgi,

    This issue is resolved by using static variables for the pivot grid and configurator and initializing them only once in controller's constructor.

    Thank you,


Back to Top