ListView Class
Allows you to display a collection of items in a multi column format. Header text can be included at the top of a column along with the ability to specify the width and horizontal alignment of each column.
Namespace: elsystem.windows.forms
Properties
Additional
properties, methods, and events are described in the classes listed
under Inheritance Hierarchy (see below).
| Name | Type | Description | |
|
|
BorderStyle | object | Gets or sets the style of the control border. See BordeStyle for a list of values. |
|
|
ColumnsCount | int | Gets the number of columns in the control. |
|
|
Columns | object | Gets the collection of all columns that appear in the control. See ColumnHeaderCollection. |
|
|
FullRowSelect | bool | True if clicking an item selects all its subitems. |
|
|
HideSelection | bool | True if the selected item does not remain highlighted when the control loses focus. |
|
|
Items | object | Gets all items in the control as a Vector object. |
|
|
MaximumRowNumber | int | Gets or sets the maximum number of rows displayed on a single page in the control before scrolling occurs. |
|
|
MultiSelect | bool | True if the user can select more than one cell, row, or column at a time. |
|
|
RowsCount | int | Gets the total number of rows included in the control. |
|
|
SelectedIndices | object | Gets the indexes of the selected items in the control. |
|
|
SelectedItems | object | Gets the items that are selected in the control as a Vector object. |
|
|
Sorting | object | Gets or sets the sort order for items in the control. See SortOrder for a list of values. |
Additional
properties, methods, and events are described in the classes listed
under Inheritance Hierarchy (see below).
Methods
| Name | Description | |
|
|
AddColumns(string) | Add columns using a list of string titles. |
|
|
AddColumns(object) | Add columns using a list of ColumnHeader objects. |
|
|
AddRow(ListViewItem) | Add row using a ListViewItem (object). |
|
|
AddRow(Object) | Add row using a list of Objects (object). |
|
|
Clear() | Removes all rows from the control. |
|
|
Create() | Initializes a new instance of a ListView. |
|
|
Create(width,height) | Initializes a new instance of a ListView. Parameters include integer values for the Width and Height of the control. |
|
|
DeleteRow(index) | Removes the specified row (0 based index) from the control. |
|
|
EnsureVisible | |
|
|
FindItemWithText(text) | First ListViewItem that begins with the specified text value. |
|
|
InsertRow(index, items) | Inserts a row at index with items. |
|
|
RemoveGradient | Removes the gradient. |
|
|
SetLinearGradient(mode, startColor, endColor) | Creates a linear gradient listview background. See LinearGradientMode and Color for lists of possible values. |
|
|
SetRadialGradient(startColor, endColor) | Creates a radial gradient listview background. See Color for a list of possible values. |
Events
| Name | Description | |
|
|
SelectedIndexChanged |
Occurs when a listview item is selected or changed. See EventArgs for the properties returned by the handler's args parameter. |