Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by Michael on Jul 06, 2009 13:16
open dhtmlx forum
setVerificator parameters

If you look at the parameter definition below, it states that the index is passed as an argument, but it actually passes the "column title". Which is correct?

setVerificator(ind,verifFunction)

ind - column index (0 based)
verifFunction - function (object) which should verify cell value (if not specified, then value will be compared to empty string). Two arguments will be passed into it: value and column name
Answer posted by dhxSupport on Jul 07, 2009 01:13
>>Two arguments will be passed into it: value and column name
in dthmlxDataProcessor ver. 2.0:
Value and column name passed as parameters of "verifFunction" function:
dp.setVerificator(ind,verifFunction);
function verifFunction(value,colName){
return value>0;
}
in dhtmlxDataProcessor ver. 2.1 arguments passed in  the verifFunction function is value, row id, column index:
dp.setVerificator(ind,verifFunction);
function verifFunction(value,rowId,columnIndex){
return value>0;
}