BackColor Property
- Namespace
TXTextControl
- Package
TXTextControl.asTextControl. WinForms. SDK TXTextControl.from the private NuGet feed or Text Control Offline PackagesWindows. Forms. dll
Description
Overridden. Gets or sets the background color of the control. The property value can be set to Color.Transparent to have a transparent background. A transparent background is only possible if the ViewMode property has been set to SimpleControl. A TextControl uses the ControlStyles.SupportsTransparentBackColor style to enable transparency. This style shows the contents of the control's parent in the control's background. If there is another control between the control and its parent, the TextControl will not show the control in the middle. See the description of the ControlStyles enumeration in the .net Framework documentation.
Syntax
public override Color BackColor { get; set; }Public Overrides Property BackColor As ColorExamples
The following example uses TextControl.BackColor to set the text control's background color. The change is then applied to the active document or user interface.
textControl.BackColor = System.Drawing.Color.LightSteelBlue;
textControl.Update();textControl.BackColor = System.Drawing.Color.LightSteelBlue
textControl.Update()