views:

3876

answers:

3

I am using a datagrid. It has itemEditor components, combo boxes, etc. as aprt of columns. Ideally datagrid.invalidateList() method works to reload the datagrid with new dataProvider data.

But, for me it is appending to the old data and new data gets added below the older data. I am not able to fix this reload of datagrid.

A: 

I'm having a little trouble understanding exactly what your problem is. Can't you just replace DataGrid.dataProvider with the new collection?

cliff.meyers
A: 

Well I got that. I just had to make my array empty.

so now its likeif arr is an array acting as dataprovider.

arr=[];

This makes the array empty and then i make it as dataprovider.

+2  A: 

Use ArrayCollection, not Array! ArrayCollection provides all the change notification machinery you need. Array does not.

verveguy