[问题] textbox 绑定 IEnumerable<String>

楼主: archknight (布丁牛奶)   2020-01-23 15:33:30
我想做一个在 textbox 上输入文字就提示的功能
就像就 google 打 y 会出现 yahoo 之类的提示
我在网上找到一个 library
https://github.com/Nimgoble/WPFTextBoxAutoComplete
但是在第三个步骤卡住了
3.Create a textbox and bind the "AutoCompleteItemsSource" to a collection of
IEnumerable<String>
不知道要怎么进行下一步
我看官方教学
https://docs.microsoft.com/zh-tw/dotnet/api/system.collections.ienumerable?view=netframework-4.8
点击 textbox 的时候 在命令列有出现 John Jim Sue
但是没有出现提示 不知道哪里错误
以下是程式码
https://github.com/BudinMilk/textbox_autocomplete/tree/master/textbox_autocomplete
请大家指点 谢谢
作者: k659292 (malone)   2020-01-24 11:10:00
虽然没用过这个,但ms有自己写一个这种套件,应该更简单使用,搜寻ajaxtookit
楼主: archknight (布丁牛奶)   2020-01-25 15:50:00
这个更简单吗,我试试看,谢谢您!请问有连结吗,我找到好几个不知哪个才是?
作者: YahooTaiwan (超可爱南西我老婆)   2020-01-26 03:09:00
先把 MVVM 学好
楼主: archknight (布丁牛奶)   2020-01-26 11:33:00
好的,感谢您!
作者: nwish (WiSH)   2020-02-05 19:46:00
可以用select2做

Links booklink

Contact Us: admin [ a t ] ucptt.com