Back to Devexpress

RepositoryItemTokenEdit.CustomDropDownControl Property

windowsforms-devexpress-dot-xtraeditors-dot-repository-dot-repositoryitemtokenedit-8a8b1a21.md

latest3.6 KB
Original Source

RepositoryItemTokenEdit.CustomDropDownControl Property

Gets or sets the custom drop-down control for this TokenEdit.

Namespace : DevExpress.XtraEditors.Repository

Assembly : DevExpress.XtraEditors.v25.2.dll

NuGet Package : DevExpress.Win.Navigation

Declaration

csharp
[Browsable(false)]
[DefaultValue(null)]
[DXCategory("Appearance")]
public CustomTokenEditDropDownControlBase CustomDropDownControl { get; set; }
vb
<DXCategory("Appearance")>
<Browsable(False)>
<DefaultValue(Nothing)>
Public Property CustomDropDownControl As CustomTokenEditDropDownControlBase

Property Value

TypeDefaultDescription
DevExpress.XtraEditors.Popup.CustomTokenEditDropDownControlBasenull

A DevExpress.XtraEditors.Popup.CustomTokenEditDropDownControlBase class descendant that serves as the custom drop-down control for this TokenEdit.

|

Remarks

By default, the TokenEdit features a simple combo box-like drop-down that lists all available tokens. You can replace this drop-down with your own control if it derives from the DevExpress.XtraEditors.Popup.CustomTokenEditDropDownControlBase class. See the TokenEdit with Custom Drop-Down Control topic for an example.

The following code snippet (auto-collected from DevExpress Examples) contains a reference to the CustomDropDownControl property.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

winforms-tokenedit-dropdown-with-treelist/CS/TokenEditTest/Form1.cs#L21

csharp
void InitTokenEdit() {
    tokenEdit.Properties.CustomDropDownControl = new CustomTokenEditDropDownControl();
    for(int i = 0; i < 20; i++) {

winforms-tokenedit-dropdown-with-treelist/VB/TokenEditTest/Form1.vb#L23

vb
Private Sub InitTokenEdit()
    tokenEdit.Properties.CustomDropDownControl = New CustomTokenEditDropDownControl()
    For i As Integer = 0 To 19

See Also

TokenEdit with Custom Drop-Down Control

RepositoryItemTokenEdit Class

RepositoryItemTokenEdit Members

DevExpress.XtraEditors.Repository Namespace