delete

Triggered when a node is about to be deleted as of a consequence of user interaction. Preventable.

Event Data

e.sender kendo.ui.OrgChart

The OrgChart instance that triggered the event.

e.dataItem Object

The data item of the node that is being deleted.

e.preventDefault Function

If invoked prevents delete.

Example

<div id="orgchart"></div>

<script>
    $("#orgchart").kendoOrgChart({
        dataSource: [
            { id: 1, name: "Jane", title: "Boss", expanded: true },
            { id: 2, name: "John", title: "Lead", expanded: true, parentId: 1 },
            { id: 3, name: "Jill", title: "Worker", expanded: true, parentId: 2 },
            { id: 4, name: "James", title: "Worker", expanded: true, parentId: 2 },
        ],
        delete: function(e) {
            e.preventDefault();
        }
    });
</script>
In this article