Label Class

A label is a control that you can use to display text that cannot be directly changed by the user.

As the Label class is a subclass of the Control class, it inherits all of the properties and methods defined in the Control class and Window class.

You can write logic that changes a label in response to events at run time. For example, if your application takes a while to commit a change, you could display a processing-status message in a label. You can also use a label to identify a control (for example, a TextBox control) that does not have its own caption property.

A label can be set to automatically resize to the caption size.

The Label class provides the following subclasses.

For a summary of the constants, properties, method, and events defined in the Label class, see "Label Class Constants", "Label Properties", "Label Method", and "Label Events", in the following subsections.