MVVM DataGrid SelectedItems无法绑定

时间:2015-02-10 10:11:40

标签: c# xaml silverlight mvvm datagrid

我有Silverlight MVVM项目,无法从ViewModel中的XAML代码中获取DataGrid SelectedItems ...

<gps:DataGrid
            ItemsSource="{Binding Nodes}"

            SelectedItems="{Binding Node, Mode=TwoWay}"

            Grid.Row="2"
            HeadersVisibility="None"
            HorizontalContentAlignment="Stretch">
            <gps:DataGrid.Columns>
               ...
            </gps:DataGrid.Columns>
        </gps:DataGrid>

我收到错误"The property "SelectedItems" does not have an accessible setter" 如何在ViewModel中获取此属性?

0 个答案:

没有答案