ASP.NET Pack Programmer's Guide
CancelEventArgs Class
See Also
 





Provides a value to use with cancellable events.

Namespace: MindFusion.Mapping
Package: Events.js

 Syntax

JavaScript  Copy Code

// class
CancelEventArgs.prototype = {}

 Example

The following code handles the collectionChanging event of the decorations property of a DecorationLayer. The handler receives an argument of type NotifyCollectionChangingEventArgs, which derives from CancelEventArgs:

JavaScript  Copy Code

var m = MindFusion.Mapping;

markers.decorations.collectionChanging.addEventListener(handleCollectionChanging);


function (handleCollectionChanging) (sender, args )
{
     if(args.action == m.NotifyCollectionChangedAction.Add)
     {
          args.cancel = true;
     }
}

 Inheritance Hierarchy

MindFusion.Mapping.EventArgs
    MindFusion.Mapping.CancelEventArgs
        MindFusion.Mapping.NotifyCollectionChangingEventArgs

 See Also

CancelEventArgs Members
MindFusion.Mapping Namespace