AnsweredAssumed Answered

Why won't my features populate to my form?

Question asked by csergent08 on May 15, 2015
Latest reply on May 15, 2015 by csergent08

I populate my form based on a map click event which had been working, but no longer is. I have uploaded the current code on Github at: csergent45/streetSigns · GitHub


If you would like to see how to re-create the error that I am running into, I have a screen recording explaining how:


The error that I receive is: Uncaught TypeError: Cannot read property 'defaultPrevented' of undefined from:



The code that populates or should populate my for input boxes is the following:

 /* Get support information on click */
        var supportId, type, address;
        app.supportLayer.on("click", function (evt) {

            // declare rest endpoint values
            supportId = evt.graphic.attributes.SUPPORTID;
            type = evt.graphic.attributes.TYPE;
            address = evt.graphic.attributes.ADDRESS;



            /* Enter your domain item and then the element to populate */
            populateSelect("TYPE", "type", "support");
            populateSelect("SIZE_", "size", "support");
            populateSelect("MATERIAL", "material", "support");
            populateSelect("BASE", "base", "support");
            populateSelect("RATING", "rating", "support");

            // Show supports form for updating 

            document.getElementById("address").value = address;
            document.getElementById("supportId").value = supportId;
            document.getElementById("type").value = type;