MindFusion.Charting for JavaScript Programmer's Guide
Control.controlUnload Event
See Also
 






Raised when the control is unloaded.

Namespace: MindFusion.Common
File: 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 EventArgs instance, which contains event data. This object will be passed to the handler function as the second argument.

 Example

The following code uses the controlUnloaded event to dispose a Window instance.

JavaScript  Copy Code

// Handle the controlUnload event.
window1.controlUnload.addEventListener(handleWindowUnload);

// This is the handler function of the wndow1.controlUnload event.
// The sender argument is a reference to the Window.
function handleWindowUnload(sender) {
 // Hide the window header.
 sender.dispose();

}

 See Also

Control Members
Control Class
MindFusion.Common Namespace