Which is the best way to switch dataset for a grid?
I tried to set the grid.dataSource.dataSource = null; and then setting it to a new array of data, but it seem like the old data just stays in the grid regardless.
grid.dataSource.dataSource = null is an incorrect syntax. If you want to change the dataSource, then you need to set the grid.dataSource to a new dataAdapter or a new Array of data.
Well I had a function that did the entire Smart('#grid', class... thing, and I called that when the data changed, but this was where I noticed that the data in the grid, stayed the same even though the data that was being put into the data adapter as data source, was a new set of data.
So what part of the grid initialization should be redone (if not all) to switch out all the data in the grid, if not the entire Smart('#grid', class... section?