Selected Items using MVVM in WinRT

前端 未结 3 523
北荒
北荒 2021-01-04 13:02

I\'m struggling to find a way to bind the SelectedItems property in a ListView to the view model.

Previously I used this: http://www.codeproject.com/Articles/412417/

3条回答
  •  攒了一身酷
    2021-01-04 13:33

    Turns out binding to the attached property was failing because the type of the attached property was being seen as

    From the output window in Visual Studio:

    type ('null')

    After further research it became apparent that any generic class would fail to bind with this exact error. As a quick fix I simply changed the type to "object".

提交回复
热议问题