Quantcast
Channel: Windows Presentation Foundation (WPF) forum
Viewing all articles
Browse latest Browse all 18858

Combobox with Auto Complete Facility in WPF

$
0
0

Hello Guys,

I am trying to achive Auto Complete feature in Combo Box in WPF.

I tried the using the below sample from this site.

http://dotbay.blogspot.ae/2009/04/building-filtered-combobox-for-wpf.html

it works fine when the combo box is not bound.

when it is bound to any object data is show in the list.

I used the below class to bind.

FilteredComboBox1.ItemsSource = cat;
FilteredComboBox1.DisplayMemberPath = "CategoryName";
FilteredComboBox1.SelectedValuePath = "CategoryID";

public class testData
    {
        private int _catID;
        private string _catName;
        public testData(int CategoryID, string CategoryName)
        {
            _catID = CategoryID;
            _catName = CategoryName;
        }
        public int CategoryID { get; set; }
        public string CategoryName { get; set; }
    }

Please advice.

regards

James 


Beginner


Viewing all articles
Browse latest Browse all 18858

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>