cancelOpen

Since: Editor 1.6.2

Form open action was cancelled by the preOpen event.
Please note - this property requires the Editor extension for DataTables.

Deprecated!

As of v1.7.3 this feature has been deprecated. This feature has not yet been scheduled for removal, but its use is discouraged and the alternatives discussed below should be used.

The preOpenCancelled event should now be used for naming consistency with the other pre*Cancelled events.

Description

It is possible for an open action triggered by edit(), inline(), etc to be cancelled by the preOpen event. When you are subscribing an open you need to know if preOpen cancelled the opening of the form so you can also remove your open event. This event provides that ability, letting you know when the open was cancelled by preOpen.

Type

function( e, mode, action )

Parameters:

Example

Using open and cancelOpen events:

editor
	.one('open.myNamespace', function () {
		// Remove cancel open
		editor.off('cancelOpen.myNamespace');

		// Do something...
	})
	.one('cancelOpen.myNamespace', function () {
		editor.off('open.myNamespace');
	})
	.inline(this);