Skip to content

Latest commit

 

History

History
48 lines (35 loc) · 1.19 KB

File metadata and controls

48 lines (35 loc) · 1.19 KB
sidebar_label afterClear
title afterClear event
description You can learn about the afterClear event in the documentation of the DHTMLX JavaScript Spreadsheet library. Browse developer guides and API reference, try out code examples and live demos, and download a free 30-day evaluation version of DHTMLX Spreadsheet.

afterClear

:::caution The afterClear event has been deprecated in v4.3. The event will continue work, but you'd better apply a new approach:

spreadsheet.events.on("afterAction", (actionName, config) => {
    if (actionName === "clear") {
        console.log(actionName, config);
    }
});

For more details about the new concept, see Spreadsheet actions. :::

Description

@short: Fires after a spreadsheet is cleared

Usage

afterClear: () => void;

Example

const spreadsheet = new dhx.Spreadsheet("spreadsheet", {});
spreadsheet.parse(data);

// subscribe on the "afterClear" event
spreadsheet.events.on("afterClear", function(){
    console.log("A spreadsheet is cleared");
    return false;
});

Changelog: Added in v4.2

Related articles: Event handling