MindFusion.Charting for JavaScript Programmer's Guide
Control.draw 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

Draws the control.

Namespace: MindFusion.Common
File: Control.js

## Syntax

JavaScript Copy Code
function draw ()

### Return Value

Type: HTMLElement
HTMLElement. The control DOM element.

## Example

The following code creates a new ListView control and calls its draw method to render it on the web page.

JavaScript Copy Code
// Create a new ListView control. // This list view will serve as a drag source. var list1 = new ui.ListView(); list1.theme = "business"; // Load the items data list1.fromObject(data); // Add event handlers list1.itemDragStart.addEventListener(listDragStart); list1.itemDragEnd.addEventListener(listDragEnd); // Draw the control and append it to the page DOM. document.body.appendChild(list1.draw()); // Prepare the control for user interaction. list1.attach();

## See Also

Control Members
Control Class
MindFusion.Common Namespace