ASP.NET Pack Programmer's Guide
Control.controlUnload Event
See Also
 





Raised when the Control is unloaded.

Namespace: MindFusion.Mapping
Package: Control.js

 Syntax

JavaScript  Copy Code

EventDispatcher controlUnload

 Event Data

The event handler method receives the following arguments:
sender
A Control instance, which is the source of the event. This object will be passed to the handler function as the first argument.
args
An EmptyEventArgs instance, which contains event data. This object will be passed to the handler function as the second argument.

 Example

The following example creates a new MapView using a <DIV> element called "mapview" that we've declared in the HTML code of the page. Then it handles the controlUnload event. The MapView class derives from Control.

JavaScript  Copy Code

var m = MindFusion.Mapping;

// create a new instance of the mapView
var view = new m.MapView(document.getElementById("mapView"));
view.theme = "light";
...................
.....................
view.controlUnload.addEventListener( handleControlUnload );

function handleControlUnload( sender, args )
{
    if (sender == view)
    {
       //do something
    }
}

 See Also

Control Members
Control Class
MindFusion.Mapping Namespace