Next
Update
Prev
View Data

This sample Grid demonstrates how to represent a Grid by calling the setDataURLEx() method to get the Dataset information from an URL of the XML file, and the data used in this sample Grid can be imported by using the getCollection() method. Click the button below the sample Grid, then the XML-formatted data will pop up.

var gridApp, gridRoot, dataGrid, collection;

function gridReadyHandler(id) {
  gridApp = document.getElementById(id);
  gridRoot = gridApp.getRoot();

  gridApp.setLayout(layoutStr);
  gridApp.setDataURLEx(gridDataURL);
}

function getCollectionXMLData() {
  if (collection == null)
    collection = gridRoot.getCollection();
    
  if (collection == null) {
    alert("The collection object cannot be found.");
    return;
  }
  
  var data = collection.toXMLString();
  alert(data);
}

© 2017 KoolChart. All rights reserved.