esri.dijit.editing.Editor not starting correctly

Discussion created by rollinsio on Sep 13, 2010
Latest reply on Oct 28, 2010 by rollinsio
I am creating a map using the JavaScript API.  For some reason, despite verifying everything against the samples, my Editor will not startup correctly.  In Chrome I'm getting a "DOM exception 8", which is indicative that an object is not in the DOM when it is referenced.  When I inspect the div which the editor should be contained in, there are plenty of nested divs, but I'm not sure which ones may be missing.

I'm putting everything in Ext components.  So far, the map and the template picker work correctly, just not the editor.

Any help would be greatly appreciated.

Here is the code for the function to set up the template picker and the editor:

initEditor: function(results){

        var editorPanel = this.get('editorpanel');
        var templatePickerPanel = editorPanel.get('templatepickerpanel');
        var editorWidgetPanel = editorPanel.get('editorwidgetpanel');
        var layers =, function(result) {
            return {featureLayer:result.layer};
        var templateLayers =, function(result){
            return result.layer;
        this.templatePicker = new esri.dijit.editing.TemplatePicker({
            featureLayers: templateLayers,
            group: true,
            rows: 'auto',
            columns: 2
        }, templatePickerPanel.body.dom);
        var settings = {
            templatePicker: this.templatePicker,
            geometryService: new esri.tasks.GeometryService(""),
            layerInfos: layers,
            toolbarVisible: true,
            createOptions: {
            polygonDrawTools: [ esri.dijit.editing.Editor.CREATE_TOOL_FREEHAND_POLYGON,
            toolbarOptions: {
                reshapeVisible: true,
                cutVisible: true,
                mergeVisible: true
        var params = {settings: settings};

        this.editorWidget = new esri.dijit.editing.Editor(params, editorWidgetPanel.body.dom);