If I am populating my grid as such how to I clear it.....when I rerun my function to get new data in a new area the last results are there untill the code finishes running....I want that to clear first before running the code.
Function updateGrid(featureSet) {
var data = arrayUtils.map(featureSet.features, function (entry, i) {
return {
id: entry.attributes.OBJECTID,
SITENAME: entry.attributes.SITENAME,
WATERBODY: entry.attributes.WATERBODY,
ACCESSAREA: entry.attributes.ACCESSAREA,
LOCATION: entry.attributes.LOCATION
};
});
// If you use a store...
dataStore = new Memory({
"data": data,
"idProperty": "id"
});
gridNoColumnSets.set("store", dataStore);
gridNoColumnSets.startup();
}