Visual Basic Reference

LostFocus Event (UserControl Object and UserDocument Object)

See Also    Example    Applies To

Occurs in the object or constituent control when focus leaves it.

Syntax

Subobject_LostFocus()

The LostFocus event syntax has these parts:

Part Description
object An object expression that evaluates to an object in the Applies To list.

Remarks

This LostFocus event is not the same LostFocus extender event that the developer who uses object handles. This LostFocus event is for the author of object, and is internal to object.

This event is useful if object needs to know that the focus is now on it.

Object itself can get focus only when the CanGetFocus property is True and there are no constituent controls that can receive focus.

The LostFocus event is raised before the ExitFocus event.