Project

General

Profile

Bug #17291 » jsfunc.evalfield_20071229.diff

Administrator Admin, 2007-12-29 23:35

View differences:

jsfunc.evalfield.js Sat Dec 29 23:32:57 2007
function evalFunc_parseDouble(value) {
var theVal = ''+value;
var dec=0;
var neg='';
if (!value) return 0;
for (var a=theVal.length; a>0; a--) {
if (theVal.substr(a-1,1)=='.' || theVal.substr(a-1,1)==',') {
......
}
}
dec = this.getNumChars(dec)+'00';
if (theVal.substr(0,1)=='-') {
theVal=theVal.substr(1);
neg='-';
}
theVal=this.parseInt(this.noSpace(theVal))+TS.decimalSign+dec.substr(0,2);
theVal=(theVal*100?neg+theVal:theVal);
return theVal;
}
(2-2/2)