JavaScript

canNamedLayoutSelect

Arguments

eobject

An object passed to the event that contains the following properties:

layoutNamestring

The name of the layout or <Default Layout>, indicating that the user selected the default layout.

Description

Fires when the user tries to change the named Layout. This event is only available if layout designs are enabled. If the event returns false, the action is cancelled.

Discussion

The canNamedLayoutSelect event is triggered when the user tries to change the named Layout. Multiple named layouts can be created for a Grid Component. The Has named layouts property in the Grid Component Properties must be enabled as well as several layouts defined for the Grid. The name of the selected layout can be accessed using the e object.

To prevent the user from changing the active named Layout, the event can return false. For example:

return false;