View
This property returns and sets the appearance of the ListItem objects in a ListView control.
Syntax
object.View [= value]
Parameters
- object
- Object expression that evaluates to a ListView control.
- value
- Integer or constant that specifies the control's appearance. Following are the settings for value:
- 0 (default)
- Icon. A full-sized (standard) icon and a corresponding text label represent each ListItem object.
- 1
- SmallIcon. A small icon and a corresponding text label, which appears to the right of the icon, represent each ListItem object. ListItem objects appear horizontally.
- 2
- List. A small icon and a corresponding text label, which appears to the right of the icon, represent each ListItem object. ListItem objects appear vertically, each on its own line with information arranged in columns.
- 3
- Report. A small icon and a corresponding text label represent each ListItem object. You can provide additional information about each ListItem object in a subitem. The icons, text labels, and information appear in columns with the leftmost column containing the small icon, followed by the text label. Additional columns display the text for each of the item's subitems.
Remarks
In Icon view only, use the LabelWrap property to specify if the ListItem object's labels are wrapped.
In Report view, you can hide the column headers by setting the HideColumnHeaders property to True. You also can use the ColumnClick event and the Sorted, SortOrder, and SortKey properties to sort the ListItem objects or subitems when a user chooses a column header. The user can change the size of the column by selecting the right border of a column header and dragging it to the desired size.