This documentation is archived and is not being maintained.
ListBox::Rows Property
Visual Studio 2010
Gets or sets the number of rows displayed in the ListBox control.
Assembly: System.Web (in System.Web.dll)
| Exception | Condition |
|---|---|
| ArgumentOutOfRangeException | The specified number of rows is less than one or greater than 2000. |
Use the Rows property to specify the number of rows to display in the ListBox control.
Caution |
|---|
The number of rows must be between one and 2000. Values outside of this range will raise an exception. |
The value of the Rows property is stored in view state.
| Topic | Location |
|---|---|
| How to: Add ListBox Web Server Controls to a Web Forms Page | Building ASP .NET Web Applications |
| How to: Add ListBox Web Server Controls to a Web Forms Page | Building ASP .NET Web Applications |
Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows XP SP2 x64 Edition, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2
The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.
Show:
Caution