Select to view content in your preferred language

Layer will not load - Uncaught TypeError: Cannot read property 'on' of null

1715
1
09-18-2017 04:55 AM
PeteSmyth
New Contributor

I am beginning to learn to use the ArcGIS API for Javascript.

I am trying to add a layer of Traffic Lights from an Open Data WMS data feed but I get the following error:

ExportWMSImageParameters.js:5 Uncaught TypeError: Cannot read property 'on' of null
at Object.set (ExportWMSImageParameters.js:5)
at a.set (init.js:237)
at Object.set [as layer] (init.js:326)
at h (init.js:309)
at Object.h (init.js:309)
at Object.set (init.js:218)
at Object.postscript (init.js:217)
at new <anonymous> (init.js:228)
at Object.b.attach (WMSLayerView2D.js:6)
at a._attachLayerView (MapView.js:35)

Please see my HTML, CSS and Javascript files on JSBin

0 Kudos
1 Reply
KenBuja
MVP Esteemed Contributor
0 Kudos