Home

Awesome

AutoCompleteTextView

Description

Multiple Selection

Delete Items

NugetPackage

https://www.nuget.org/packages/Xamarin.RisePlugin.AutoCompleteTextView

Usage

Add the following NuGet package to your solution.

You must add this line to your AppDelegate.cs before you use AutoCompleteTextView

Xamarin.RisePlugin.AutoCompleteTextView.iOS.AutoCompleteTextViewRenderer.Init();

You must call these properties NamePath, ItemTemplate, SelectedItemTemplate, ItemsSource, SelectedItemsSource Like

            auto.ItemsSource = list;
            auto.SelectedItemsSource = new List<test>();
            auto.NamePath = "Text";
            auto.ItemTemplate =  new DataTemplate(() =>
            {
                var stc = new StackLayout() { BackgroundColor = Color.Blue };
                var lbl = new Label();
                lbl.SetBinding(Label.TextProperty, "Text");
                stc.Children.Add(lbl);
                return stc;
            });
            auto.SelectedItemTemplate =  new DataTemplate(() =>
            {
                var stc = new StackLayout() { BackgroundColor = Color.Blue };
                var lbl = new Label();
                lbl.SetBinding(Label.TextProperty, "Text");
                stc.Children.Add(lbl);
                return stc;
            });
Platforms
IOS
Android

Propertys

PropertyWhat it does
TextColorSet editor text color.
FontSizeSet editor font size.
FontFamilySet editor font family.
FontAttributeSet editor font FontAttribute.
BackgroundColorSet view background color .
TextBackGroundColorSet only editor background color .
PlaceholderColorSet editor placeholder color.
BorderColorSet editor border color.
BorderThicknessSet editor border thickness.
BackButtonPressDeleteSelectedClicking back button deletes last selected item.
ClickDeleteSelectedDelets clicked item.
SeparatorColorSet separator color dropdown.
SeparatorThicknessSet separator thickness dropdown.
SameItemControlChecks selected items, will skip item if this is an already existing one. (Only work SelectionMode.Multiple)
SearchTypeSet searching criteria
NamePathType the name you want to show up in the dropdown.
SelectionModeYou can select none, single or multiple items.
RowHeightSet dropdown rows height
SelectAfterTextSetting the status of the text when selecting an object from dropdown. (Clear = clear the text, Complete = sets the name of the item you select to text, Default = does nothing)
ItemsSourceThe list you want to show up.
SelectedItemsSourceSelected item list
ItemTemplateYou can customize the visuals of the dropdown items.
SelectedItemTemplateYou can customize the visuals of the selected items.
SelectItemWhen an dropdown item is selected, properties of that item and the index returns.
SelectSameItemWhen an dropdown selected item is similar, properties of that item and the index returns.
BackButtonPressDeleteWhen an delete item with back button, properties of that item and the index returns.
TextChangedTriggered when text changes..
ClickSelectedItemTriggered when click selected item..

ItemTemplate And SelectedItemTemplate