NavigationItem.EnableChanged

Syntax

EnableChanged: function (sender, args)

Parameters

sender. Event source.

args. Event information.

Description

The EnableChanged event occurs after changing tab availability.

Example

To execute the example, the page must contain the NavigationBar component named navigationBar (see Example of Creating the NavigationBar Component). Add an element availability event handler for the first tab:

navigationBar.getLayoutItems()[0].EnableChanged.add(function (sender, args) {
    console.log("Side panel element availability is changed")
});

Change availability of the first panel element:

// Change availability of the first panel element
navigationBar.getLayoutItems()[0].setEnabled(False);

As a result the console displays information about changing element availability:

Side panel element availability is changed

See also:

NavigationItem