HeaderPane
Main
Hide
Share Link
Print

SearchModeEnum Enumeration

Defines how the list is searched while the user types.

Namespace: Softelvdm.SftBoxNET
Assembly: Softelvdm.SftBoxNET

Syntax

public enum SearchModeEnum;
Public Enum SearchModeEnum

Values

NameDescription
NoneTyping doesn't search the list.
PrefixThe first item whose text starts with the typed text is selected in the list.
ExactThe first item whose text equals the typed text is selected in the list.
AutoCompleteThe first item whose text starts with the typed text is selected in the list, and the rest of its text is added to the typed text and selected, so typing continues to replace it.
ContainsThe first item whose text contains the typed text is selected in the list.
FilterThe list shows only the items whose text contains the typed text, and their parent items, and the first of them is selected. Adding or removing items while the list is filtered ends the filter.
ManualThe application searches the list itself, in response to the SftBox.EditTextChanged event.

Comments

Defines how the list is searched while the user types.

Examples

C# View entire sample code

            // the installed fonts, each name shown in its own font, with an image for TrueType and OpenType fonts
            sftBox3.FillFontNames(FontListOptionsEnum.ShowInFont | FontListOptionsEnum.ShowTypeImage);
            sftBox3.Text = "Segoe UI";
            if (sftBox3.SelectedItem == null && sftBox3.Items.Count > 0)
                sftBox3.SelectedItem = sftBox3.Items[0];

            BindLookup();

            FillCombo(comboSearch, typeof(SearchModeEnum), sftBox5.SearchMode);
            FillCombo(comboAlignment, typeof(DropDownAlignmentEnum), sftBox1.DropDownAlignment);
            FillCombo(comboPosition, typeof(DropDownPositionEnum), sftBox1.DropDownPosition);
            FillCombo(comboNumbering, typeof(RowHeaderNumberingEnum), sftBox7.List.RowHeaders.Numbering);
            FillCombo(comboDarkMode, typeof(DarkModeEnum), sftBox1.DarkMode);
            FillCombo(comboHighContrast, typeof(HighContrastModeEnum), sftBox1.HighContrastMode);
            DpiChanged += Form1_DpiChanged;
        }

VB.NET View entire sample code

        SftBox3.FillFontNames(FontListOptionsEnum.ShowInFont Or FontListOptionsEnum.ShowTypeImage)
        SftBox3.Text = "Segoe UI"
        If SftBox3.SelectedItem Is Nothing AndAlso SftBox3.Items.Count > 0 Then
            SftBox3.SelectedItem = SftBox3.Items(0)
        End If

        BindLookup()

        FillCombo(ComboSearch, GetType(SearchModeEnum), SftBox5.SearchMode)
        FillCombo(ComboAlignment, GetType(DropDownAlignmentEnum), SftBox1.DropDownAlignment)
        FillCombo(ComboPosition, GetType(DropDownPositionEnum), SftBox1.DropDownPosition)
        FillCombo(ComboNumbering, GetType(RowHeaderNumberingEnum), SftBox7.List.RowHeaders.Numbering)
        FillCombo(ComboDarkMode, GetType(DarkModeEnum), SftBox1.DarkMode)
        FillCombo(ComboHighContrast, GetType(HighContrastModeEnum), SftBox1.HighContrastMode)
    End Sub

See Also Classes | SftBox/NET 3.0