ASP.NET BorderStyle Property


Web Control Standard Properties Reference Complete Web Control Standard Properties Reference

Definition and Usage

The BorderStyle property is used to set or return the border style of a control.

Syntax

<asp:webcontrol id="id" BorderStyle="style" runat="server" />

Possible Style Values

Value Description
notSet Border style is not set
none Defines no border
dotted Defines a dotted border
dashed Defines a dashed border
solid Defines a solid border
double Defines two borders. The width of the two borders are the same as the border-width value
groove Defines a 3D grooved border. The effect depends on the border-color value
ridge Defines a 3D ridged border. The effect depends on the border-color value
inset Defines a 3D inset border. The effect depends on the border-color value
outset Defines a 3D outset border. The effect depends on the border-color value

Example

The following example sets the border style of a table:

<form runat="server">
<asp:Table runat="server" BorderStyle="dotted"
BorderWidth="5" GridLines="vertical">
  <asp:TableRow>
    <asp:TableCell>Hello</asp:TableCell>
    <asp:TableCell>World</asp:TableCell>
  </asp:TableRow>
</asp:Table>
</form>

Show example »

Web Control Standard Properties Reference Complete Web Control Standard Properties Reference

SHARE THIS PAGE

COLOR PICKER

colorpicker