MDIClient.add

Overview | Methods | This Package | All Packages

MDIClient.add

Adds a child form to the MDI container.

Syntax

public void add( Control ctl )

Parameters

ctl

A Control object that specifies the MDI child form to add.

Remarks

The child form specified in the ctl parameter must be a Form object that is marked as an MDI child. You should not call this method directly. Instead, you should set the child form's MDIParent property from within the Properties window or call the Form object's setMDIParent method:

// Incorrect.
Form child = new ChildForm();
this.getMDIClient().add(child);

// Correct.
Form child = new ChildForm();
child.setMDIParent(this);

See Also   remove