95
Prevent Negative Numbers in a numeric textbox
posted

Hi,

I have an igGrid with edit mode dialog. On it, I have a textbox which accepts only numbers. I'm trying to prevent negative numbers from being entered in this field. I tried the below:

settings.ColumnSetting().ColumnKey("test").DefaultValue(0).Required(true).NumericEditorOptions(opt=> {

opt.ValidatorOptions(vopt =>
{
 vopt.ValueRange(0);
});

});

When i run with above and after I enter a correct value, as soon as textbox loses focus, I get an error on infragistics.lob.js.

 Unable to get property 'toString' of undefined or null reference

Please help.

Regards,

Guru

Parents Reply Children
No Data