View Full Version : How to avoid Cannot call method 'toFixed' of undefined in Axis.js in extjs4.1

14 Sep 2013, 12:54 AM
I already asked this question in this forum http://stackoverflow.com/questions/18761675/how-to-avoid-cannot-call-method-tofixed-of-undefined-in-axis-js-in-extjs4-1 .

In my application am getting Cannot call method 'toFixed' of undefined in Axis.js.In higher version Google chrome Version 26 browser.So My application is not loading.Can anybody tell what is problem how to solve this problem

I am rounding the two decimal value for chart .It is running in google chrome version 23

toFixed : function(number, precision){
var multiplier = Math.pow( 10, precision );
return Math.round( number * multiplier ) / multiplier;


15 Sep 2013, 11:01 PM
Add number = number || 0; in the start of your method. Or it is not yours? :)