I had a need for the column data in a table to be only numeric.
Without giving it much thought I just set the renderer to Numeric but
when I entered new text in, naturally it allowed me to enter anything.
So then I added a celleditor.TextField to the column and created a
simple validation function to test if the data is numeric:

var chkNum = function(value, oldValue){
   if (isNaN(value))
    return oldValue
  else return value
}

The FIRST time you enter data in the cell, the validation works
perfect. If you enter non-numeric data it gets changed back to the
original numeric data that was in the cell. But if you do it again
(and all subsequent entries), it allows the non-numeric data. No
validation is performed. I put a debug line in the validation function
and it is only called for the first edit, not on any subsequent edits.

If this is a bug, as I am sure it is, I will enter it into the bug
system. Just let me know if I am loosing my mind or not. Or is there
an easier way to restrict data entry to be numeric data?

Thanks,
Jim

------------------------------------------------------------------------------
Crystal Reports - New Free Runtime and 30 Day Trial
Check out the new simplified licensign option that enables unlimited
royalty-free distribution of the report engine for externally facing 
server and web deployment.
http://p.sf.net/sfu/businessobjects
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Reply via email to