ActiveForm

Returns the form that is the active window.

Syntax

object.ActiveForm

The object placeholder represents an object expression that evaluates to an object.

Remarks

Use the ActiveForm property to access a form's properties or to invoke its methods — for example, Screen.ActiveForm.Height = 200.

When a control on a form has the focus, that form is the active form on the screen (Screen.ActiveForm).