WebPartZoneBase::BorderColor Property

 

Gets or sets the color for the border of a WebPartZoneBase control.

Namespace:   System.Web.UI.WebControls.WebParts
Assembly:  System.Web (in System.Web.dll)

public:
property Color BorderColor {
	virtual Color get() override;
	virtual void set(Color value) override;
}

Property Value

Type: System.Drawing::Color

A Color that contains the border color. The default color is Gray.

The base BorderColor property is overridden by the WebPartZoneBase class to set a default color for zone borders.

You can set the BorderColor property for a WebPartZoneBase control either declaratively or programmatically. The border appears only when the zone is in a page display mode in which WebPartZoneBase class user interface (UI) features are visible, such as EditDisplayMode or DesignDisplayMode.

The following code example demonstrates the declarative use of the BorderColor property on a WebPartZone control. For the full code example, including the code-behind source file and the .aspx page that contains the zone in this code, see the WebPartZoneBase class overview.

Notice that the BorderColor attribute is set to a specific named color. After you load the page into a browser and switch the page into design display mode, you can see the effect of the property.

No code example is currently available or this language may not be supported.

.NET Framework
Available since 2.0
Return to top
Show: