HtmlTable.Width Property

Gets or sets the width of the HtmlTable control.

Namespace: System.Web.UI.HtmlControls
Assembly: System.Web (in system.web.dll)

public:
property String^ Width {
	String^ get ();
	void set (String^ value);
}
/** @property */
public String get_Width ()

/** @property */
public void set_Width (String value)

public function get Width () : String

public function set Width (value : String)

Not applicable.

Property Value

The width of the HtmlTable control.

Use the Width property to control the width of the HtmlTable control. The width is normally specified in pixels. However, you can also specify a percentage of the browser window width by appending a percent sign (%) to the value. For example, the value 100% indicates a width for the table that is the full width of the browser window. The table automatically expands and contracts as the user changes the window size.

NoteNote:

If you specify a value that is smaller than is required to display the contents of the HtmlTable control, this property is ignored.

The following code example demonstrates how to use the Width property to programmatically control the width of the HtmlTable control.

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

Windows 98, Windows Server 2000 SP4, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.

.NET Framework

Supported in: 3.0, 2.0, 1.1, 1.0

Community Additions

ADD
Show: