我当前正在使用以下代码来填充组合框:
combobox.DataSource = datatable;
combobox.DisplayMember = "Auftragsnummer";
combobox.ValueMember = "ID";
有没有办法显示多列。我为 DisplayMember 尝试了“Auftragsnummer、Kunde、Beschreibung”,但没有成功。
您不能有多个列。尽管您可以将多个字段串联为显示成员
查看:如何绑定组合,以便显示成员是源数据表的 2 个字段的连接? https://stackoverflow.com/questions/1006521/how-do-i-bind-a-combo-so-the-displaymember-is-concat-of-2-fields-of-source-datata
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)