pavan.adiga

TypeError: Cannot call method 'insertBefore' of null

Discussion created by pavan.adiga on Jan 26, 2014
Latest reply on Jan 27, 2014 by btfou
Hi,

I am using the following ESRI libraries :

dojo.require("esri.map");
dojo.require("esri.layers.MapImage");
dojo.require("esri.layers.MapImageLayer");
dojo.require("esri.geometry.Extent");
dojo.require("esri.SpatialReference");
dojo.require("esri.dijit.HomeButton");
dojo.require("esri.dijit.LocateButton");
dojo.require("esri.InfoTemplate");

dojo.require("esri.layers.FeatureLayer");

dojo.ready(init);

I am getting this error : "Uncaught TypeError: Cannot call method 'insertBefore' of null", when I run the code. The error occurs in "init.js" method of ESRI.

The code works fine when do not use the feature layer and comment it out.

dojo.require("esri.layers.FeatureLayer");

The error only occurs in particular systems, and the code works fine in other system.

This is very confusing. Could anyone point what I am missing out.

Thanks in advance.

Outcomes