Hi,
Using: SmartClient Version: 8.2/LGPL Development Only (built 2011-12-05)
On IE 8.
When the user cursors to the end of my grid I want a new record to be created with default values
I have a piece of code that according to samples should do this:
It almost works but I end up with both a blank row and new row with defaults
How do I stop the blank row from coming up?
Regards,
Greg
Using: SmartClient Version: 8.2/LGPL Development Only (built 2011-12-05)
On IE 8.
When the user cursors to the end of my grid I want a new record to be created with default values
I have a piece of code that according to samples should do this:
Code:
grid.addRowEditorEnterHandler(new RowEditorEnterHandler()
{
@Override
public void onRowEditorEnter(RowEditorEnterEvent event)
{
CasualHourRecord chr = (CasualHourRecord) event.getRecord();
if (chr == null) {
Log.debug("OnRowEditorEnter - record is null");
CasualHourRecord newCHRecord = createNewRecord();
grid.addData(newCHRecord);
}
else {
chr.setRecState(CasualHourRecord.REC_STATE_UPDATED);
}
}
});
How do I stop the blank row from coming up?
Regards,
Greg
Comment