Hi,
I have use grid in my panel with delete column and one add button in panel which add the new row in grid.
when I delete the row from grid then it works, but when I add a new item then some times it gives following Exception.
I have refresh the grid while deleteing the item.
@Override
public void refresh() {
locoContainer.removeAllItems();
locoContainer.addAll(dataList);
}
Exception:
[i]
Caused by: java.lang.IllegalArgumentException: Item with specified ID does not exist in data source
at com.vaadin.ui.Grid.scrollTo(Grid.java:5408)[69:com.vaadin.server:7.6.5]
at com.vaadin.ui.Grid.scrollTo(Grid.java:5386)[69:com.vaadin.server:7.6.5]
at com.knorrbremse.icom.leader.ui.components.grid.RestoreSelectionListener.selectByBean(RestoreSelectionListener.java:64)
at com.knorrbremse.icom.leader.ui.components.grid.RestoreSelectionListener.detach(RestoreSelectionListener.java:77)
at sun.reflect.GeneratedMethodAccessor89.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)[:1.8.0_40]
at java.lang.reflect.Method.invoke(Unknown Source)[:1.8.0_40]
at com.vaadin.event.ListenerMethod.receiveEvent(ListenerMethod.java:508)[69:com.vaadin.server:7.6.5]
... 57 more
[/i]
Is any pointer to solve this problem?