jQWidgets Forums

jQuery UI Widgets Forums TreeGrid jqxtreegrid virtual mode with dynamic columns

Tagged: 

This topic contains 1 reply, has 2 voices, and was last updated by  Peter Stoev 9 years, 6 months ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author

  • jahnvi25
    Participant

    everything is working fine with virtual mode as expected.but i need to set some columns dynamically based on data returned from server..
    so i am doing

    loadServerData:function(…){
    //call ajax and in success set the column
    $(“#table”).jqxTreeGrid({ columns: tblColumns}); // where tblColumns comes from server
    callback({ records: tbData,totalrecords:tbData.length });
    }
    //this is not working… i keep getting errors. but if i use just static columns.. then its working fine..

    how can i make dynamic columns ?


    Peter Stoev
    Keymaster

    Hi jahnvi25,

    You should know the columns and they should be defined when you create the widget. You can make a server request before the initialization to get your columns, but during the creating of the TreeGrid, you should know and define them. You cannot define them during the widget’s rendering.

    Best Regards,
    Peter Stoev

    jQWidgets Team
    http://www.jqwidgets.com

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.