@dev wrote:
I'm able to handle diagram events of objects dropped, and extract the data from the node model from the palette that is copied over to the diagram via console.log. When I try to call a function from the each Set iterator, the called function (nodeHanlder) is not recognized. Using angular with IntellJ with chrome on osx. The error is telling me that the Angular object doesn't exist.
core.es5.js:1020 ERROR TypeError: Cannot read property 'nodeHandler' of undefinedthis.diagram.addDiagramListener('ExternalObjectsDropped', this.objectDroppedHandler); objectDroppedHandler(e: DiagramEvent): void { e.subject.each( (node) => **this.nodeHandler(node));** } nodeHandler(node: go.Node): void { }
Posts: 1
Participants: 1