MindFusion.Charting for JavaScript Programmer's Guide
Control.dispose Method
See Also
Collapse All Expand All Language Filter: All Language Filter: Multiple Language Filter: None Language Filter: C# Language Filter: Visual Basic Language Filter: Java Language Filter: JavaScript Language Filter: C++ Language Filter: XAML

C#
Visual Basic
Java
JavaScript
C++
XAML

Dispose the control.

Namespace: MindFusion.Common
File: Control.js

## Syntax

JavaScript Copy Code
function dispose ()

## Remarks

Detaches control event handlers and removes its element from the DOM, if it was internally created.

## Example

The following code uses the dispose method to hide a Clock gauge that is no longer rendered on the web page.

JavaScript Copy Code
function stopClock() { clearInterval(timerId); document.getElementById("clock").parentNode.style.visibility = "hidden"; var clock = g.OvalGauge.find("clock"); if (clock) clock.dispose(); }

## See Also

Control Members
Control Class
MindFusion.Common Namespace