Bewerken

Share via


ListView.Scrollable Property

Definition

Gets or sets a value indicating whether a scroll bar is added to the control when there is not enough room to display all items.

public:
 property bool Scrollable { bool get(); void set(bool value); };
public bool Scrollable { get; set; }
member this.Scrollable : bool with get, set
Public Property Scrollable As Boolean

Property Value

true if scroll bars are added to the control when necessary to allow the user to see all the items; otherwise, false. The default is true.

Remarks

When this property is set to true, the ListView displays a vertical scroll bar to use when the number of items exceeds the size of the client area of the control. You can use this property to ensure that the user can access all items that are available in the ListView control.

Note

In versions of the .NET Framework prior to version 2.0, the column headers were not painted correctly when setting this property to false and resizing the control to make it larger. To work around this issue, set this property to true in a ResizeBegin event handler and set it back to false in a ResizeEnd event handler.

Applies to