PDA

View Full Version : [1.2.4] Exceptin on GridView getCell method



micgala
5 Aug 2009, 6:35 AM
Hi.

Its just too much effort to create a test case, but it happens if I:

Populate a grid, then select a line, then reconfigure it, then select another line, then reconfigure again, and select a line.

Method


public Element getCell(int row, int col) {
return getRow(row).getElementsByTagName("td").getItem(col);
}
should be changed by:


public Element getCell(int row, int col) {
Element rowEl = getRow(row);
if (rowEl != null) {
return rowEl.getElementsByTagName("td").getItem(col);
}
return null;
}
A workaround, if anyone else experience this, is to override that method.

Thanks,
Michel.