Search
BaseForm.addControl Method
See Also
 






Adds the specified control to the collection of controls.

Namespace: MindFusion.Scheduling
File: BaseForm.js

 Syntax

JavaScript  Copy Code

function addControl (control)

 Parameters

control

Object. The control to add.

 Example

The following code adds a new text area to a custom form. The custom form is represented by a class that extends BaseForm:

JavaScript  Copy Code

drawContent() {
  super.drawContent();

// create a text-area for the item subject
  var control = this.createTextArea({ id: "subject", initValue: this.item.subject, events: { keydown: this._areaKeyDown } });
  control.element.style.width = "200px";
  this.addControl(control);
………..
}

 See Also