This documentation is archived and is not being maintained.
HtmlImage.Border Property
.NET Framework 1.1
Gets or sets the width of a frame for an image.
[Visual Basic] Public Property Border As Integer [C#] public int Border {get; set;} [C++] public: __property int get_Border(); public: __property void set_Border(int); [JScript] public function get Border() : int; public function set Border(int);
Property Value
The width (in pixels) of a frame for an image.
Remarks
Use this property to create a frame with the specified width (in pixels) for an image.
Example
[Visual Basic, C#, JScript] The following example demonstrates how to use the Border property to specify a frame with a width of 5 pixels for an HtmlImage control.
[Visual Basic] <%@ Page Language="VB" AutoEventWireup="True" %> <html> <head> </head> <body> <form runat="server"> <h3>HtmlImage Example</h3> <img id ="Image1" Src="image1.jpg" Width="500" Height="226" Alt="Image 1" Border="5" Align="center" runat=server/> </form> </body> </html> [C#] <%@ Page Language="C#" AutoEventWireup="True" %> <html> <head> </head> <body> <form runat="server"> <h3>HtmlImage Example</h3> <img id ="Image1" Src="image1.jpg" Width="500" Height="226" Alt="Image 1" Border="5" Align="center" runat=server/> </form> </body> </html> [JScript] <%@ Page Language="JScript" AutoEventWireup="True" %> <html> <head> </head> <body> <form runat="server"> <h3>HtmlImage Example</h3> <img id ="Image1" Src="image1.jpg" Width="500" Height="226" Alt="Image 1" Border="5" Align="center" runat=server/> </form> </body> </html>
[C++] No example is available for C++. To view a Visual Basic, C#, or JScript example, click the Language Filter button
in the upper-left corner of the page.
Requirements
Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family
See Also
HtmlImage Class | HtmlImage Members | System.Web.UI.HtmlControls Namespace
Show: