标签: mvvm combobox serial-port
我想将可用ViewBag.DeptList = new SelectList(_listSelectItem, "Value", "Text", firstOrDefault.Text); 绑定到MVVM中的组合框,所以我有这个:
ViewBag.DeptList = new SelectList(_listSelectItem, "Value", "Text", firstOrDefault.Text);
XAML:
model.DEPARTMENTI
视图模型:
SerialPort
那么我应该怎么做才能将serialport绑定到组合框?谢谢!