【发布时间】:2011-11-08 06:51:11
【问题描述】:
我有一个 WPF 数据网格,我想获取网格中所有选定的单元格,我可以通过循环遍历所有项目来做到这一点,那么有没有内置的方法可以做到这一点?
我在DataGrid中设置了两个属性:
SelectionMode="Extended" // for multiple selection
SelectionUnit="Cell" //row should not be selected but cell should be
谢谢。
【问题讨论】: