BillHoney

Intermitant "'this.spatialReference' is null" Bug

Discussion created by BillHoney on Mar 16, 2013
Latest reply on Apr 23, 2013 by BillHoney
Hi,
I'm getting an intermittent error on startup of my application.
It occurs maybe 1 time in 10
The stack trace is all in anonymous code (i.e. not caused by my code)

The stack trace in deep inside the 3.3  serverapi.arcgisonline.com code:


[INDENT]'this.spatialReference' is null or not an object
info=this.spatialReference._getInfo()
_23c=this._getFrameWidth()
this._setClipRect()
this.onResize(ne,wd,ht)
self._resize()[/INDENT]



I have NO resize logic in my app.
I have tried adding some in the style of earlier versions of the api  , but this has made no difference.
my app is quite large.
Can anyone advise ?
Bill

// Makes no difference 
function window_onResize() {
 var resizeTimer;
 clearTimeout(resizeTimer);
 resizeTimer = setTimeout(function () {
  if (map) {
   map.resize();
   map.reposition();
  }
 }, 500); 
} 

Outcomes