Back to Devexpress

RepositoryItemLookUpEdit.UseDropDownRowsAsMaxCount Property

windowsforms-devexpress-dot-xtraeditors-dot-repository-dot-repositoryitemlookupedit-1e83122b.md

latest2.9 KB
Original Source

RepositoryItemLookUpEdit.UseDropDownRowsAsMaxCount Property

Gets or sets whether the number of visible data rows limits the height of the dropdown window.

Namespace : DevExpress.XtraEditors.Repository

Assembly : DevExpress.XtraEditors.v25.2.dll

NuGet Package : DevExpress.Win.Navigation

Declaration

csharp
[DefaultValue(false)]
[DXCategory("Behavior")]
public bool UseDropDownRowsAsMaxCount { get; set; }
vb
<DXCategory("Behavior")>
<DefaultValue(False)>
Public Property UseDropDownRowsAsMaxCount As Boolean

Property Value

TypeDefaultDescription
Booleanfalse

true if the height of the dropdown cannot be greater than the number of data rows; otherwise, false.

|

Remarks

You can control the height of the dropdown by using the RepositoryItemLookUpEdit.DropDownRows property, which specifies the number of rows simultaneously displayed in the dropdown window. The following image shows a LookUpEdit control with the RepositoryItemLookUpEdit.DropDownRows property set to 7 and the UseDropDownRowsAsMaxCount property set to false (default value):

Because the data source only contains five data rows, you see two empty rows at the bottom of the dropdown. To vertically shrink the dropdown to fit available data rows, set the UseDropDownRowsAsMaxCount property to true. In this case, the height of the dropdown cannot be greater than the number of data rows.

See Also

DropDownRows

DataSource

RepositoryItemLookUpEdit Class

RepositoryItemLookUpEdit Members

DevExpress.XtraEditors.Repository Namespace