ListBox::PreferredHeight Property
.NET Framework (current version)
Gets the combined height of all items in the ListBox.
Assembly: System.Windows.Forms (in System.Windows.Forms.dll)
This property enables you to determine the height that the ListBox needs to be sized to, in order to display every available item in the list and to avoid displaying vertical scroll bars. If the amount of items in the ListBox is large, sizing the control using the value of the PreferredHeight property might cause the ListBox to be sized outside of the client area of the form or the ListBox container.
.NET Framework
Available since 1.1
Available since 1.1
Show: