Xceed Toolkit for .NET Maui v2.0 Documentation
Xceed.Maui.Toolkit Assembly / Xceed.Maui.Toolkit Namespace / AutoCompleteTextBox Class
Members Example


In This Topic
    AutoCompleteTextBox Class
    In This Topic
    TextBox which can propose various possible values for the Text that is being typed. 
    Object Model
    AutoCompleteTextBox ClassICustomFilterAction Interface
    Syntax
    'Usage
     
    
    Dim instance As AutoCompleteTextBox
    Remarks

    The suggestions are based on the provided ItemsSource.

    The filtering of this ItemsSource can be customized to provide more flexibility in the available values.

    The appearance of the filtered items can also be customized to give them a specific look.

    Example

    The following code would display these results if a user types the letter "a" inside the AutoCompleteTextBox: 

    <xctk:AutoCompleteTextBox ClearButtonVisibility="WhileEditing"
                              WidthRequest="200">
     <xctk:AutoCompleteTextBox.ItemsSource>
      <x:Array Type="{x:Type x:String}">
       <x:String>Alpha</x:String>
       <x:String>American</x:String>
       <x:String>Arabic</x:String>
       <x:String>Amphibian</x:String>
       <x:String>Boat</x:String>
       <x:String>Car</x:String>
      </x:Array>
     </xctk:AutoCompleteTextBox.ItemsSource>
     <xctk:AutoCompleteTextBox.ItemTemplate>
      <DataTemplate>
       <Label Text="{Binding}"
              TextColor="White"
              FontSize="18"
              Margin="5"/>
      </DataTemplate>
     </xctk:AutoCompleteTextBox.ItemTemplate>
    </xctk:AutoCompleteTextBox>
    Inheritance Hierarchy

    System.Object
       Microsoft.Maui.Controls.BindableObject
          Microsoft.Maui.Controls.Element
             Microsoft.Maui.Controls.NavigableElement
                Microsoft.Maui.Controls.VisualElement
                   Microsoft.Maui.Controls.View
                      Microsoft.Maui.Controls.Compatibility.Layout
                         Microsoft.Maui.Controls.TemplatedView
                            Xceed.Maui.Toolkit.Control
                               Xceed.Maui.Toolkit.TextBox
                                  Xceed.Maui.Toolkit.AutoCompleteTextBox

    Requirements

    Target Platforms: Windows 11, Windows 10, Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

    See Also