I want to Display only 6 records from the XML file I am reading from, but the code load all the records to the grid
var table = new AW.XML.Table;
table.setURL("data/companies-simple.xml");
table.request();
var columns = ["Ticker", "Company Name", "Market Cap.", "$ Sales", "Employees"];
var obj = new AW.UI.Grid;
obj.setColumnCount(6);
obj.setHeaderText(columns);
var str = new AW.Formats.String;
var num = new AW.Formats.Number;
obj.setCellFormat([str, str, num, num, num]);
obj.setSelectorVisible(true);
obj.setSelectorWidth(25);
obj.setSelectionMode("single-row");
obj.setCellModel(table);
obj.setVirtualMode(true);
obj.setRowCount(6);
obj.setRowIndices( [0,1,2,3,4,5] );
obj.refresh();
document.write(obj);
table.setURL("data/companies-simple.xml");
table.request();
var columns = ["Ticker", "Company Name", "Market Cap.", "$ Sales", "Employees"];
var obj = new AW.UI.Grid;
obj.setColumnCount(6);
obj.setHeaderText(columns);
var str = new AW.Formats.String;
var num = new AW.Formats.Number;
obj.setCellFormat([str, str, num, num, num]);
obj.setSelectorVisible(true);
obj.setSelectorWidth(25);
obj.setSelectionMode("single-row");
obj.setCellModel(table);
obj.setVirtualMode(true);
obj.setRowCount(6);
obj.setRowIndices( [0,1,2,3,4,5] );
obj.refresh();
document.write(obj);
rahul
March 14,